home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus 1997 #3
/
Amiga Plus CD - 1997 - No. 03.iso
/
pd
/
programmierung
/
alienbreed3d2_src
/
amos
/
gamelinker.amos
/
gamelinker.amosSourceCode
Wrap
AMOS Source Code
|
1997-01-31
|
87KB
|
4,380 lines
Set Buffer 300
Reserve As Work 15,500000
ALMAX=19
Dim LEVNAME$(15),OBJGFX$(29),SFX$(59),BULNAME$(19),VOI(19),BGV(19),BLT(19)
Dim VECGFX$(29),WALLGFX$(15),WALLHEIGHT(15),GFXTYPE$(10),GUNOBJ(9)
Dim AIC(19),DBB(19),BOW(19),BOFC(19),BDV(19),NOB(19),BEF(19),BMS(19),BGT(19),IGT(19)
Dim GUNNAME$(9),GUNBUL(9),BULANIM(19,1,19,5),BULF(19,1),ALNAME$(ALMAX),ALSTAT(ALMAX,20)
Dim OGFRAMES(29,63,3),DEFB$(9),RESB$(9),FOLB$(9),RETB$(9),OBNAME$(30),OBSTAT(30,19)
Dim OBDEFAF(30,20,5),GSFX(9),BSFX(19),ISFX(19)
Dim OBACTAF(30,20,5),BACKSFX(15)
Dim ALBRIGHT(19),FLOORHURT(15),FLOORNOISE(15)
Dim ALANIM(ALMAX,10,19,10),ALSHOTXOFF(19),ALSHOTYOFF(19)
Dim LEVMUSIC$(15),ECHO(59)
' ammo 0=health 1=jetpack fuel
' gun 0=shield 1=jetpack
Dim AMMOGIVE(30,21),GUNGIVE(30,11)
GFXTYPE$(0)="Bitmap"
GFXTYPE$(1)="Vector"
GFXTYPE$(2)="Lightsourced palette 1"
GFXTYPE$(3)="Lightsourced palette 2"
GFXTYPE$(4)="Lightsourced palette 3"
GFXTYPE$(5)="Lightsourced palette 4"
RED=1
WHITE=2
GREEN=3
Global MP,LEVNAME$(),OBJGFX$(),SFX$(),BULNAME$(),VOI(),BGV(),BLT()
Global VECGFX$()
Global AIC(),DBB(),BOW(),BOFC(),BDV(),NOB(),BEF(),BMS(),ALNAME$(),BGT(),IGT()
Global GUNNAME$(),GUNBUL(),BULANIM(),BULF(),ALSTAT()
Global OGFRAMES(),RED,WHITE,GREEN,ALANIM(),GUNOBJ()
SFX$(59)="* RESERVED FOR FOOTSTEP SOUNDS *"
DEFB$(0)="Prowl Randomly "
DEFB$(1)="Fly Randomly "
RESB$(0)="Charge "
RESB$(1)="Charge To Side "
RESB$(2)="Attack with Gun "
RESB$(3)="Charge (Flying) "
RESB$(4)="Charge To Side (Flying) "
RESB$(5)="Attack with Gun (Flying) "
FOLB$(0)="Pause "
FOLB$(1)="Approach "
FOLB$(2)="Approach To Side "
FOLB$(3)="Approach (Flying) "
FOLB$(4)="Approach To Side (Flying) "
RETB$(0)="Pause "
RETB$(1)="Attack To Side (unarmed) "
RETB$(2)="Guard Start Control Pt "
For A=0 To 15
B$=Chr$(65+A)
' 1234567890123456789**2345678901234567890
LEVNAME$(A)=" LEVEL "+B$+" "
Next
For A=0 To 19
BULNAME$(A)="BULLET TYPE "+Chr$(A+65)
Next
For A=0 To ALMAX
ALNAME$(A)="ALIEN "+Chr$(A+65)
For B=0 To 10
ALANIM(A,B,0,8)=-1
For C=1 To 19
ALANIM(A,B,C,0)=-1
ALANIM(A,B,C,8)=-1
Next : Next
Next
For A=0 To 9
GUNBUL(A)=A
GUNNAME$(A)="GUN "+Chr$(A+65)
Next
LEVELDIR$=""
FTMNAME$=""
GGNAME$=""
BLURB$=""
Screen Open 0,640,256,4,Hires
Flash Off : Cls 0
Wait Vbl
Limit Mouse
Set Curs %111100,%1000010,%10100101,%10100101,%10000001,%10100101,%1011010,%111100
Colour 1,$F44
RED=1
Colour 2,$FFF
WHITE=2
Colour 3,$F0
GREEN=3
Menu$(1)="(IN 1,0)FILE "
Menu$(1,1)="(IN 1,0)Load Default "
Menu$(1,2)="(IN 1,0)Load Game Link File "
Menu$(1,3)="(IN 1,0)Save Game Link File "
Menu$(1,4)=" "
Menu$(1,5)="(IN 1,0)Quit "
Menu$(2)="(IN 1,0)EDIT:- "
Menu$(2,1)="(IN 1,0)LEVELS ->"
Menu$(2,2)="(IN 1,0)GRAPHICS ->"
Menu$(2,3)="(IN 1,0)VECTORS ->"
Menu$(2,4)="(IN 1,0)SAMPLES ->"
Menu$(2,5)="(IN 1,0)BULLETS ->"
Menu$(2,6)="(IN 1,0)GUNS ->"
Menu$(2,7)="(IN 1,0)ALIENS ->"
Menu$(2,8)="(IN 1,0)OBJECTS ->"
Menu$(2,9)="(IN 1,0)PLAYERS ->"
Menu$(2,10)="(IN 1,0)MISC ->"
Menu$(2,1,1)="(IN 1,0)Set Levels Directory "
Menu$(2,1,2)="(IN 1,0)Change Level Names "
Menu$(2,2,1)="(IN 1,0)Set Object GFX Frames "
Menu$(2,2,2)="(IN 1,0)Set Floor Tile Filename "
Menu$(2,2,3)="(IN 1,0)Set Wall GFX Filenames "
Menu$(2,2,4)="(IN 1,0)Set Texture Filename "
Menu$(2,3,1)="(IN 1,0)Set Vector Filenames "
Menu$(2,4,1)="(IN 1,0)Set SFX Filenames "
Menu$(2,4,2)="(IN 1,0)Select Background SFX "
Menu$(2,4,3)="(IN 1,0)Define Echoed SFX "
Menu$(2,5,1)="(IN 1,0)Define Bullet Data"
Menu$(2,6,1)="(IN 1,0)Define Gun Types"
Menu$(2,7,1)="(IN 1,0)Define Alien Stats"
Menu$(2,8,1)="(IN 1,0)Define Object Stats"
Menu$(2,9,1)="(IN 1,0)Define Player Stats"
Menu$(2,10,1)="(IN 1,0)Define Floor Damage Values "
Menu$(2,10,2)="(IN 1,0)Define Floor Footstep Sounds"
Menu$(2,10,3)="(IN 1,0)Select Level Music Files "
Menu On
Gosub ROSCRN
Repeat
Repeat
Until Choice
If Choice(1)=1
If Choice(2)=5
End
End If
If Choice(2)=3
Gosub LINKFILESAVE
End If
If Choice(2)=2
Gosub LINKFILELOAD
End If
End If
If Choice(1)=2
If Choice(2)=1
If Choice(3)=1
Gosub SETLEVELS
End If
If Choice(3)=2
Gosub SETLEVELNAMES
End If
End If
If Choice(2)=2
If Choice(3)=1
Gosub SETOBJGFXNAMES
End If
If Choice(3)=2
Gosub SETFLOORTILENAME
End If
If Choice(3)=3
Gosub SETWALLNAMES
End If
If Choice(3)=4
Gosub SETTEXNAME
End If
End If
If Choice(2)=3
If Choice(3)=1
Gosub SETVECTORNAMES
End If
End If
If Choice(2)=4
If Choice(3)=1
Gosub SETSFXNAMES
End If
If Choice(3)=2
Gosub SETBACKSFX
End If
If Choice(3)=3
Gosub SETECHOSFX
End If
End If
If Choice(2)=5
If Choice(3)=1
Gosub SETBULLETDATA
End If
End If
If Choice(2)=6
If Choice(3)=1
Gosub SETGUNBULLETS
End If
End If
If Choice(2)=7
If Choice(3)=1
Gosub SETALIENNAME
End If
End If
If Choice(2)=8
If Choice(3)=1
Gosub SETOBJNAME
End If
End If
If Choice(2)=9
If Choice(3)=1
Gosub SETPLAYERSTATS
End If
End If
If Choice(2)=10
If Choice(3)=1
Gosub SETFLOORDAMAGE
Else If Choice(3)=2
Gosub SETFLOORSFX
Else
Gosub PICKLEVELMUSIC
End If
End If
End If
Until 0
End
Procedure LK[VA]
Loke MP,VA
Add MP,4
End Proc
Procedure DK[VA]
Doke MP,VA
Add MP,2
End Proc
Procedure PK[VA]
Poke MP,VA
Add MP,1
End Proc
LINKFILESAVE:
MP=Start(15)
' 0-63=Path of level directory
For A=1 To 64
If A<=Len(LEVELDIR$) Then PK[Asc(Mid$(LEVELDIR$,A,1))] Else PK[0]
Next
Print MP-Start(15);" Level Names"
For A=0 To 15
For B=1 To 40
PK[Asc(Mid$(LEVNAME$(A),B,1))]
Next
Next
Print MP-Start(15);" Object gfx filenames"
For A=0 To 29
For B=1 To 64
If B<=Len(OBJGFX$(A)) Then PK[Asc(Mid$(OBJGFX$(A),B,1))] Else PK[0]
Next
Next
Print MP-Start(15);" SFX filenames"
For A=0 To 59
For B=1 To 64
If B<=Len(SFX$(A)) Then PK[Asc(Mid$(SFX$(A),B,1))] Else PK[0]
Next
Next
Print MP-Start(15);" floor tile filename"
For A=1 To 64
If A<=Len(FTMNAME$) Then PK[Asc(Mid$(FTMNAME$,A,1))] Else PK[0]
Next
For A=1 To 64
If A<=Len(TEXNAME$) Then PK[Asc(Mid$(TEXNAME$,A,1))] Else PK[0]
Next
Print MP-Start(15)
Add MP,64*2
Print MP-Start(15);" gun filename"
For A=1 To 64
If A<=Len(GGNAME$) Then PK[Asc(Mid$(GGNAME$,A,1))] Else PK[0]
Next
Print MP-Start(15);" blurb filename"
For A=1 To 64
If A<=Len(BLURB$) Then PK[Asc(Mid$(BLURB$,A,1))] Else PK[0]
Next
Print MP-Start(15);" bullet animation data"
For A=0 To 19
LK[VOI(A)] : LK[BGV(A)] : LK[BLT(A)] : LK[AIC(A)]
LK[BOW(A)] : LK[BOFC(A)] : LK[BDV(A)] : LK[BEF(A)]
LK[BMS(A)] : LK[BULF(A,0)] : LK[BULF(A,1)]
LK[BSFX(A)] : LK[ISFX(A)] : LK[BGT(A)] : LK[IGT(A)]
For G=0 To 1
For B=0 To 19
For C=0 To 5
PK[BULANIM(A,G,B,C)]
Next
Next
Next
Next
Print MP-Start(15);" Bullet Names"
For A=0 To 19
For B=1 To 20
If B<=Len(BULNAME$(A))
PK[Asc(Mid$(BULNAME$(A),B,1))]
Else
PK[0]
End If
Next
Next
Print MP-Start(15);" Gun names"
For A=0 To 9
For B=1 To 20
If B<=Len(GUNNAME$(A))
PK[Asc(Mid$(GUNNAME$(A),B,1))]
Else
PK[0]
End If
Next
Next
Print MP-Start(15);" Bullet type used in each gun"
For A=0 To 9
DK[GUNBUL(A)]
DK[DBB(A)]
DK[NOB(A)]
DK[GSFX(A)]
Next
Print MP-Start(15);" Names for each alien"
For A=0 To ALMAX
For B=1 To 20
If B<=Len(ALNAME$(A))
PK[Asc(Mid$(ALNAME$(A),B,1))]
Else
PK[0]
End If
Next
Next
Print MP-Start(15);" Stats for each alien type"
For A=0 To ALMAX
For B=0 To 20
DK[ALSTAT(A,B)]
Next
Next
Print MP-Start(15);" Data for graphics frames"
For A=0 To 29
For B=0 To 31
DK[OGFRAMES(A,B,0)]
DK[OGFRAMES(A,B,1)]
DK[OGFRAMES(A,B,2)/2]
DK[OGFRAMES(A,B,3)/2]
Next
Next
Print MP-Start(15);" Names for each object type"
For A=0 To 29
For B=1 To 20
If B<=Len(OBNAME$(A))
PK[Asc(Mid$(OBNAME$(A),B,1))]
Else
PK[0]
End If
Next
Next
Print MP-Start(15);" Object Statistics"
For A=0 To 29
For B=0 To 19
DK[OBSTAT(A,B)]
Next
Next
Print MP-Start(15);" Object default anim data"
For A=0 To 29
For B=0 To 19
For C=0 To 5
PK[OBDEFAF(A,B,C)]
Next
Next
Next
Print MP-Start(15);" Object activated anim data"
For A=0 To 29
For B=0 To 19
For C=0 To 5
PK[OBACTAF(A,B,C)]
Next
Next
Next
Print MP-Start(15);" Ammo collected from objects"
For A=0 To 29
For B=0 To 21
DK[AMMOGIVE(A,B)]
Next
Next
Print MP-Start(15);" Guns collected from objects"
For A=0 To 29
For B=0 To 11
DK[GUNGIVE(A,B)]
Next
Next
Print MP-Start(15);" Alien Animation Data"
For A=0 To ALMAX
For B=0 To 10
For C=0 To 19
For D=0 To 10
PK[ALANIM(A,B,C,D)]
Next : Next : Next : Next
Print MP-Start(15);" Vector gfx filenames"
For A=0 To 29
For B=1 To 64
If B<=Len(VECGFX$(A)) Then PK[Asc(Mid$(VECGFX$(A),B,1))] Else PK[0]
Next
Next
Print MP-Start(15);" Wall gfx filenames"
For A=0 To 15
For B=1 To 64
If B<=Len(WALLGFX$(A)) Then PK[Asc(Mid$(WALLGFX$(A),B,1))] Else PK[0]
Next
Next
Print MP-Start(15);" Wall heights"
For A=0 To 15
DK[WALLHEIGHT(A)]
Next
Print MP-Start(15);"Alien Torch brightnesses"
For A=0 To 19
DK[ALBRIGHT(A)]
Next
For A=0 To 9
DK[GUNOBJ(A)]
Next
DK[PLR1ALIEN]
DK[PLR2ALIEN]
Print MP-Start(15);"Floor data"
For A=0 To 15
DK[FLOORHURT(A)]
DK[FLOORNOISE(A)]
Next
For A=0 To 19
LK[ALSHOTYOFF(A)]
LK[ALSHOTXOFF(A)]
Next
For A=0 To 15
DK[BACKSFX(A)]
Next
For A=0 To 15
For B=1 To 64
If B<=Len(LEVMUSIC$(A)) Then PK[Asc(Mid$(LEVMUSIC$(A),B,1))] Else PK[0]
Next
Next
For A=0 To 59
PK[ECHO(A)]
'PK[A]
Next
Print MP-Start(15);" Length Of File"
F$=Fsel$("","","Select a file to create/overwrite. (.LNK will be added)")
If F$<>""
F$=Upper$(F$)
If Right$(F$,4)<>".LNK"
F$=F$+".LNK"
End If
A$="Y"
Cls 0 : Locate 0,10
If Exist(F$)
Pen RED : Paper 0 : Print "FILE ALREADY EXISTS, OVERWRITE?"
Input A$
A$=Upper$(Left$(A$,1))
End If
If A$="Y"
Bsave F$,Start(15) To MP
Pen GREEN : Paper 0 : Centre "** File saved successfully **"
Else
Pen RED : Paper 0 : Centre "*** File NOT saved ***"
End If
End If
Return
LINKFILELOAD:
MP=Start(15)
F$=Fsel$("","","Select a file to load")
If Right$(F$,4)<>".lnk" Then F$=F$+".lnk"
Bload F$,Start(15)
MP=Start(15)
' 0-63=Path of level directory
LEVELDIR$=""
For A=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then LEVELDIR$=LEVELDIR$+Chr$(C)
Next
Print MP-Start(15);" Level Names"
For A=0 To 15
LEVNAME$(A)=""
For B=1 To 40
LEVNAME$(A)=LEVNAME$(A)+Chr$(Peek(MP)) : Add MP,1
Next
Next
Print MP-Start(15);" Object gfx filenames"
For A=0 To 29
OBJGFX$(A)=""
For B=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then OBJGFX$(A)=OBJGFX$(A)+Chr$(C)
Next
Next
Print MP-Start(15);" SFX filenames"
For A=0 To 59
SFX$(A)=""
For B=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then SFX$(A)=SFX$(A)+Chr$(C)
Next
Next
SFX$(59)="* RESERVED FOR FOOTSTEP SOUNDS *"
Print MP-Start(15);" floor tile filename"
FTMNAME$=""
For A=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then FTMNAME$=FTMNAME$+Chr$(C)
Next
TEXNAME$=""
For A=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then TEXNAME$=TEXNAME$+Chr$(C)
Next
Print MP-Start(15)
Add MP,64*2
Print MP-Start(15);" gun filename"
GGNAME$=""
For A=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then GGNAME$=GGNAME$+Chr$(C)
Next
Print MP-Start(15);" blurb filename"
BLURB$=""
For A=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then BLURB$=BLURB$+Chr$(C)
Next
Print MP-Start(15);" bullet animation data"
For A=0 To 19
VOI(A)=Leek(MP) : Add MP,4
BGV(A)=Leek(MP) : Add MP,4
BLT(A)=Leek(MP) : Add MP,4
AIC(A)=Leek(MP) : Add MP,4
BOW(A)=Leek(MP) : Add MP,4
BOFC(A)=Leek(MP) : Add MP,4
BDV(A)=Leek(MP) : Add MP,4
BEF(A)=Leek(MP) : Add MP,4
BMS(A)=Leek(MP) : Add MP,4
BULF(A,0)=Leek(MP) : Add MP,4
BULF(A,1)=Leek(MP) : Add MP,4
BSFX(A)=Leek(MP) : Add MP,4
ISFX(A)=Leek(MP) : Add MP,4
BGT(A)=Leek(MP) : Add MP,4
IGT(A)=Leek(MP) : Add MP,4
For G=0 To 1
For B=0 To 19
For C=0 To 5
BULANIM(A,G,B,C)=Peek(MP) : Add MP,1
Next
Next
Next
Next
Print MP-Start(15);" Bullet Names"
For A=0 To 19
BULNAME$(A)=""
For B=1 To 20
C=Peek(MP) : Add MP,1
If C<>0
BULNAME$(A)=BULNAME$(A)+Chr$(C)
End If
Next
Next
Print MP-Start(15);" Gun names"
For A=0 To 9
GUNNAME$(A)=""
For B=1 To 20
C=Peek(MP) : Add MP,1
If C<>0
GUNNAME$(A)=GUNNAME$(A)+Chr$(C)
End If
Next
Next
Print MP-Start(15);" Bullet type used in each gun"
For A=0 To 9
GUNBUL(A)=Deek(MP) : Add MP,2
DBB(A)=Deek(MP) : Add MP,2
NOB(A)=Deek(MP) : Add MP,2
GSFX(A)=Deek(MP) : Add MP,2
Next
Print MP-Start(15);" Names for each alien"
For A=0 To ALMAX
ALNAME$(A)=""
For B=1 To 20
C=Peek(MP) : Add MP,1
If C<>0
ALNAME$(A)=ALNAME$(A)+Chr$(C)
End If
Next
Next
Print MP-Start(15);" Stats for each alien type"
For A=0 To ALMAX
For B=0 To 20
ALSTAT(A,B)=Deek(MP) : Add MP,2
If ALSTAT(A,B)>32767 Then Add ALSTAT(A,B),-65536
Next
Next
Print MP-Start(15);" Data for graphics frames"
For A=0 To 29
For B=0 To 31
OGFRAMES(A,B,0)=Deek(MP) : Add MP,2
OGFRAMES(A,B,1)=Deek(MP) : Add MP,2
OGFRAMES(A,B,2)=Deek(MP)*2 : Add MP,2
OGFRAMES(A,B,3)=Deek(MP)*2 : Add MP,2
Next
Next
Print MP-Start(15);" Names for each object type"
For A=0 To 29
OBNAME$(A)=""
For B=1 To 20
C=Peek(MP) : Add MP,1
If C<>0
OBNAME$(A)=OBNAME$(A)+Chr$(C)
End If
Next
Next
Print MP-Start(15);" Object Statistics"
For A=0 To 29
For B=0 To 19
O=Deek(MP) : Add MP,2
If O>32767 Then O=O-65536
OBSTAT(A,B)=O
Next
Next
Print MP-Start(15);" Object default anim data"
For A=0 To 29
For B=0 To 19
For C=0 To 5
O=Peek(MP)
If O>127 and C=4 Then O=O-256
OBDEFAF(A,B,C)=O : Add MP,1
Next
Next
Next
Print MP-Start(15);" Object activated anim data"
For A=0 To 29
For B=0 To 19
For C=0 To 5
O=Peek(MP)
If O>127 and C=4 Then O=O-256
OBACTAF(A,B,C)=O : Add MP,1
Next
Next
Next
Print MP-Start(15);" Ammo collected from objects"
For A=0 To 29
For B=0 To 21
AMMOGIVE(A,B)=Deek(MP) : Add MP,2
Next
Next
Print MP-Start(15);" Guns collected from objects"
For A=0 To 29
For B=0 To 11
GUNGIVE(A,B)=Deek(MP) : Add MP,2
Next
Next
Print MP-Start(15);" Alien Animation Data"
For A=0 To ALMAX
For B=0 To 10
For C=0 To 19
For D=0 To 10
ALANIM(A,B,C,D)=Peek(MP) : Add MP,1
Next
If ALANIM(A,B,C,0)=255 Then ALANIM(A,B,C,0)=-1
If ALANIM(A,B,C,4)>127 Then Add ALANIM(A,B,C,4),-256
If ALANIM(A,B,C,1)>127 Then Add ALANIM(A,B,C,1),-256
If ALANIM(A,B,C,9)>127 Then Add ALANIM(A,B,C,9),-256
If ALANIM(A,B,C,8)>127 Then Add ALANIM(A,B,C,8),-256
If ALANIM(A,B,C,10)>127 Then Add ALANIM(A,B,C,10),-256
Next : Next : Next
For A=0 To 29
VECGFX$(A)=""
For B=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then VECGFX$(A)=VECGFX$(A)+Chr$(C)
Next
Next
For A=0 To 15
WALLGFX$(A)=""
For B=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then WALLGFX$(A)=WALLGFX$(A)+Chr$(C)
Next
Next
For A=0 To 15
WALLHEIGHT(A)=Deek(MP) : Add MP,2
Next
For A=0 To 19
ALBRIGHT(A)=Deek(MP) : Add MP,2
Next
For A=0 To 9
GUNOBJ(A)=Deek(MP) : Add MP,2
Next
PLR1ALIEN=Deek(MP) : Add MP,2
PLR2ALIEN=Deek(MP) : Add MP,2
For A=0 To 15
FLOORHURT(A)=Deek(MP) : Add MP,2
FLOORNOISE(A)=Deek(MP) : Add MP,2
Next
For A=0 To 19
ALSHOTYOFF(A)=Leek(MP) : Add MP,4
ALSHOTXOFF(A)=Leek(MP) : Add MP,4
Next
For A=0 To 15
BACKSFX(A)=Deek(MP) : Add MP,2
Next
For A=0 To 15
LEVMUSIC$(A)=""
For B=1 To 64
C=Peek(MP) : Add MP,1
If C<>0 Then LEVMUSIC$(A)=LEVMUSIC$(A)+Chr$(C)
Next
Next
For A=0 To 59
ECHO(A)=Peek(MP) : Add MP,1
Next
Pen GREEN : Cls 0
Centre "*** Link File Loaded ***"
Return
SETFLOORDAMAGE:
Menu Off
Repeat
Cls
Locate 0,0 : Pen GREEN
Centre "Set damage done by each type of floor:"
For A=0 To 15
Locate 0,A+2
Pen WHITE
Print " Tile : ";A+1;
Locate 40,
Print ":";
Locate 60,
Pen GREEN
Print FLOORHURT(A)
Next
Pen RED
Locate 0,31
Centre "*** DONE ***"
Repeat : Until Mouse Click
Y=Y Screen(0,Y Mouse)/8
If Y>1 and Y<(16+2)
Y=Y-2
Locate 60,Y+2
Pen RED
Input FLOORHURT(Y)
End If
Until Y=31
Cls
Menu On
Return
SETFLOORSFX:
Menu Off
Repeat
Cls
Locate 0,0 : Pen GREEN
Centre "Players' footstep noises on each type of floor:"
For A=0 To 15
Locate 0,A+2
Pen WHITE
Print " Tile : ";A+1;
Locate 40,
Print ":";
Locate 42,
Pen GREEN
If FLOORNOISE(A)>0
Print SFX$(FLOORNOISE(A)-1)
Else
Print " None."
End If
Next
Pen RED
Locate 0,31
Centre "*** DONE ***"
Repeat : Until Mouse Click
Y=Y Screen(0,Y Mouse)/8
If Y>1 and Y<(16+2)
Y=Y-2
TY=Y
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
FLOORNOISE(TY)=Y
End If
Until Y=31
Cls
Menu On
Return
SETPLAYERSTATS:
Menu Off
Repeat
Cls 0
Locate 0,0 : Pen GREEN
Centre "Define Player Statistics"
Locate 0,2
Pen WHITE
Print "Player ONE appears as alien :";
Locate 40,
Pen RED
Print ALNAME$(PLR1ALIEN)
Locate 0,4
Pen WHITE
Print "Player TWO appears as alien :";
Locate 40,
Pen RED
Print ALNAME$(PLR2ALIEN)
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)/8
If Y=2
Gosub ALIENNAMESHOW
Locate 0,0 : Print Space$(80)
Pen WHITE
Locate 0,0 : Centre "Select Player ONE's appearance:"
Locate 0,29 : Print Space$(80)
Locate 0,31 : Print Space$(70);
Locate 0,31 : Pen RED : Centre "* CANCEL *"
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)/8
Y=Y-1
If Y>=0 and Y<>30
PLR1ALIEN=Y
End If
Y=-1
Else If Y=4
Gosub ALIENNAMESHOW
Locate 0,0 : Print Space$(80)
Pen WHITE
Locate 0,0 : Centre "Select Player TWO's appearance:"
Locate 0,29 : Print Space$(80)
Locate 0,31 : Print Space$(70);
Locate 0,31 : Pen RED : Centre "* CANCEL *"
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)/8
Y=Y-1
If Y>=0 and Y<>30
PLR2ALIEN=Y
End If
Y=-1
End If
Until Y=31
Cls 0
Menu On
Return
SETGUNBULLETS:
Menu Off
Repeat
Gosub GUNTYPESHOW
Locate 0,31
Pen RED
Centre "*** DONE ***"
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y>0 and Y<31
Y=Y-1 : YC=Y/3
X=X Screen(0,X Mouse)
X=X/320
If Y mod 3=0
If X=0
Locate 4,Y+1 : Pen RED : Input "NAME: ";GUNNAME$(YC)
Else
Gosub BULDATSHOW
Repeat
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
Until F>0 and F<21
GUNBUL(YC)=F-1
End If
Else
If Y mod 3=1
If X=0
Locate 4,Y+1 : Pen RED : Input "Bullets fired/shot: ";NOB(YC)
Else
Locate 40,Y+1 : Pen RED : Input "Delay between shots: ";DBB(YC)
End If
Else
If X=0
TY=Y
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
GSFX(YC)=Y-1
Y=TY
Else
Gosub OBJNAMESHOW
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
GUNOBJ(YC)=F-1
End If
End If
End If
End If
Until Y=31
Cls 0
Menu On
Return
GUNTYPESHOW:
Cls 0
Locate 0,0
Pen GREEN : Paper 0
Centre "Player Gun Names / Bullets:"
For A=0 To 9
Locate 0,A*3+1
Pen RED
Print A; : Locate 4,
Pen WHITE
Print GUNNAME$(A);
Locate 40,
Pen GREEN : Print ":";
Locate 50,
Pen RED
Print BULNAME$(GUNBUL(A))
Pen WHITE
Print " Bullets fired/shot : ";
Pen RED
Print NOB(A);
Locate 40,
Pen WHITE
Print "Delay Between Shots (50=1sec): ";
Pen RED
Print DBB(A)
Locate 4,
Pen WHITE
Print "Gun SFX: ";
Pen RED
If GSFX(A)>=0
Print SFX$(GSFX(A));
Else
Print "None.";
End If
Locate 40,
Pen WHITE
Print "On Screen Object: ";
Pen RED
Print OBNAME$(GUNOBJ(A));
Next
Return
ROSCRN:
Cls 0
Locate 0,10
Pen RED : Paper 0
Centre "ALIEN BREED 3D"
Pen WHITE
Locate 0,12
Centre "Game Linker"
Locate 0,14
Centre "RMB to access menus.."
Locate 0,16
Centre "Program by A. Clitheroe"
Locate 0,18
Centre " "
Return
SETBULLETDATA:
Menu Off
Gosub BULDATSHOW
Gosub STATCLICKSHOW
Repeat
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y<31 and Y>0
X=X Screen(0,X Mouse)
X=X/8
If X>48
BULNUM=Y-1
Gosub CHANGEBULLETSTATS
Gosub BULDATSHOW
Gosub STATCLICKSHOW
Y=0
Else
Pen GREEN
Locate 15,Y
Input BULNAME$(Y-1)
Gosub BULDATSHOW
Gosub STATCLICKSHOW
Y=0
End If
End If
Until Y=31
Menu On
Cls 0
Return
STATCLICKSHOW:
Pen RED : Paper 0
For A=0 To 19
Locate 47,A+1
Print " | Edit Bullet Statistics"
Next
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Return
CHANGEBULLETSTATS:
Gosub BULSTATSHOW
Repeat
Pen RED : Paper 0
Locate 0,31
Centre "*** DONE ***"
Repeat
Until Mouse Click
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y=3
Pen GREEN : Paper 0
Locate 60,3
Input BDV(BULNUM)
Gosub BULSTATSHOW
End If
If Y=5
VOI(BULNUM)=1-VOI(BULNUM)
Gosub BULSTATSHOW
End If
If VOI(BULNUM)=0
If Y=6
Pen GREEN : Paper 0
Locate 60,6
Input BGV(BULNUM)
Gosub BULSTATSHOW
End If
If Y=7
Pen GREEN : Paper 0
Locate 60,7
BOW(BULNUM)=1-BOW(BULNUM)
Gosub BULSTATSHOW
End If
If Y=8
Pen GREEN : Paper 0
Locate 60,8
BOFC(BULNUM)=1-BOFC(BULNUM)
Gosub BULSTATSHOW
End If
If Y=9
OY=Y
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
BSFX(BULNUM)=Y
Y=OY
Gosub BULSTATSHOW
End If
If Y=10
Pen GREEN : Paper 0
Locate 60,10
Input BLT(BULNUM)
Gosub BULSTATSHOW
End If
If Y=11
Pen GREEN : Paper 0
Locate 60,11
Input BEF(BULNUM)
Gosub BULSTATSHOW
End If
If Y=12
Pen GREEN : Paper 0
Locate 60,12
Input BMS(BULNUM)
BMS(BULNUM)=Min(7,Max(BMS(BULNUM),0))
Gosub BULSTATSHOW
End If
If Y=13
OY=Y
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
ISFX(BULNUM)=Y
Y=OY
Gosub BULSTATSHOW
End If
If Y=14
PON=0
Gosub DEFBULANIM
Gosub BULSTATSHOW
End If
If Y=16
BGT(BULNUM)=(BGT(BULNUM)+1) mod 3
Gosub BULSTATSHOW
End If
End If
If Y=15
PON=1
Gosub DEFBULANIM
Gosub BULSTATSHOW
End If
If Y=17
IGT(BULNUM)=(IGT(BULNUM)+1) mod 3
Gosub BULSTATSHOW
End If
Until Y=31
Cls 0
Return
DEFBULANIM:
Repeat
Gosub BULANIMSHOW
Repeat
MC=Mouse Click
Until MC<>0
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
If Y=31
If X<15
BULF(BULNUM,PON)=Min(BULF(BULNUM,PON)+1,19)
For J=0 To 4
BULANIM(BULNUM,PON,BULF(BULNUM,PON),J)=BULANIM(BULNUM,PON,BULF(BULNUM,PON)-1,J)
Next
Else
If X<30
BULF(BULNUM,PON)=Max(BULF(BULNUM,PON)-1,0)
End If
End If
End If
Z=(Y-1)+(X/40)*30
DX=X mod 40
' If Y=0
' If X>40 and X<60
' Pen GREEN
' Locate 0,31 : Input "FRAME WIDTH :";BFW(BULNUM);
' End If
' If X>60
' Pen GREEN
' Locate 0,31 : Input "FRAME HEIGHT :";BFH(BULNUM);
' End If
' End If
If Y>0 and Y<31
If DX>3 and DX<7
Gosub PICKOBJGRAPHNAME
BULANIM(BULNUM,PON,Z,0)=Y-1
End If
If DX>9 and DX<13
If MC=2
FRAMEPICK[BULANIM(BULNUM,PON,Z,0),BULANIM(BULNUM,PON,Z,1)+1]
BULANIM(BULNUM,PON,Z,1)=Param-1
Gosub BULANIMSHOW
Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";L : BULANIM(BULNUM,PON,Z,1)=L-1
End If
End If
If DX>15 and DX<20
Pen GREEN
Locate 0,31 : Input "SCALED WIDTH :";BULANIM(BULNUM,PON,Z,2);
End If
If DX>22 and DX<27
Pen GREEN
Locate 0,31 : Input "SCALED HEIGHT :";BULANIM(BULNUM,PON,Z,3);
End If
If DX>29 and DX<34
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";BULANIM(BULNUM,PON,Z,4);
End If
If DX>36 and DX<40
Pen GREEN
Locate 0,31 : Input "BRIGHTNESS VALUE:";BULANIM(BULNUM,PON,Z,5);
End If
End If
Until Y=31 and X>60
Y=0
Return
Procedure FRAMEPICK[OG,SV]
FRN=Abs(SV)
If SV<0 Then FLIP=1 Else FLIP=0
If Exist(OBJGFX$(OG)+".dat")
Screen Open 1,320,128,32,Lowres
Screen Display 1,,42,,
Screen Display 0,,130+42,,
Screen 1
Curs Off : Flash Off : Cls 0
Bload OBJGFX$(OG)+".256pal",Start(15)
Bload "ab3:includes/256pal",Start(15)+1024
For A=0 To 31 :
C=Peek(Start(15)+A*2)
R=Deek(Start(15)+1024+C*6)
G=Deek(Start(15)+1026+C*6)
B=Deek(Start(15)+1028+C*6)
Colour A,(R/16)*$100+(G/16)*$10+(B/16)
Next
Bload OBJGFX$(OG)+".dat",Start(15)
WOF=Deek(Start(15)+2)
HOF=Deek(Start(15)+4)
Screen 0 : Cls 0
Locate 0,0 : Pen GREEN : Centre "[ Prev Frame ][ Next Frame ]"
Locate 0,2 : Pen GREEN : Centre "[ Flip Horizontally ]"
Locate 0,15 : Pen RED : Centre "*** DONE ***"
Locate 0,4 : Pen GREEN : Centre "Current Frame: "+Str$(FRN)
Repeat
Screen 1 : Cls 0
LX=OGFRAMES(OG,FRN-1,0)
LY=OGFRAMES(OG,FRN-1,1)
LW=OGFRAMES(OG,FRN-1,2)
LH=OGFRAMES(OG,FRN-1,3)
S=Start(15)+LX*HOF+6+LY
If FLIP=0
For A=0 To LW-1
For B=0 To LH-1
Extension_12_036E A,B,Peek(S+B+(A*HOF))
Next
Next
Else
For A=0 To LW-1
For B=0 To LH-1
Extension_12_036E LW-A,B,Peek(S+B+(A*HOF))
Next
Next
End If
Repeat : Until Mouse Click
LY=Y Screen(0,Y Mouse)
LX=X Screen(0,X Mouse)
LY=LY/8 : LX=LX/8
If LY=0
If LX<40
FRN=Max(FRN-1,1)
Else
FRN=Min(FRN+1,64)
End If
Screen 0
Locate 0,4 : Pen GREEN : Centre " Current Frame: "+Str$(FRN)+" "
End If
If LY=2
FLIP=1-FLIP
End If
Until LY=15
Screen Close 1
Screen Display 0,,42,,
End If
If FLIP=1
FRN=-FRN
End If
End Proc[FRN]
BULANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
If PON=0
A$="Animation frames for "+BULNAME$(BULNUM)
Else
A$="Impact frames for "+BULNAME$(BULNUM)
End If
Centre A$
'Locate 40,0
'Pen WHITE
'Print "Frame Width:"
'Locate 53,0
'Pen RED
'Print Using "###";BFW(BULNUM)
'Locate 60,0
'Pen WHITE
'Print "Frame Height:"
'Locate 74,0
'Pen RED
'Print Using "###";BFH(BULNUM)
For A=0 To BULF(BULNUM,PON)
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print "GF:";
Pen RED
Print Using "## ";BULANIM(BULNUM,PON,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";BULANIM(BULNUM,PON,A,1)+1;
Pen WHITE
Print "SW:";
Pen RED
Print Using "### ";BULANIM(BULNUM,PON,A,2);
Pen WHITE
Print "SH:";
Pen RED
Print Using "### ";BULANIM(BULNUM,PON,A,3);
Pen WHITE
Print "VO:";
Pen RED
Print Using "+## ";BULANIM(BULNUM,PON,A,4);
Pen WHITE
Print "BV:";
Pen RED
Print Using "## ";BULANIM(BULNUM,PON,A,5);
Print
Next
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
BULSTATSHOW:
Cls 0
Locate 0,0
Pen GREEN : Paper 0
A$="Bullet Statistics for: "+BULNAME$(BULNUM)
Centre A$
Locate 0,3
Pen WHITE
Print "Damage to target per bullet :-";
Pen RED
Locate 60,
Print BDV(BULNUM)
Locate 0,5
Pen WHITE
Print "Visible bullet or instant effect (V/I) :-";
Pen RED
Locate 60,
If VOI(BULNUM)=0
Print "VISIBLE"
Pen WHITE
Print "Gravity value :-";
Locate 60,
Pen RED
Print BGV(BULNUM)
Pen WHITE
Print "Bounce off walls (Y/N) :-";
Pen RED
Locate 60,
If BOW(BULNUM)=1
Print "YES"
Else
Print "NO"
End If
Pen WHITE
Print "Bounce off floors/ceilings (Y/N) :-";
Pen RED
Locate 60,
If BOFC(BULNUM)=1
Print "YES"
Else
Print "NO"
End If
If BOFC(BULNUM)=1
Pen WHITE
Print "Bounce Noise :-";
Pen RED
If BSFX(BULNUM)>0
Print SFX$(BSFX(BULNUM)-1)
Else
Locate 60, : Print "None"
End If
Else
Print
End If
Pen WHITE
Print "Bullet lifetime (-1 = infinite) :-";
Pen RED
Locate 60,
If BLT(BULNUM)=-1
Print "INFINITE"
Else
Print BLT(BULNUM)
End If
Pen WHITE
Print "Explosive force :-";
Pen RED
Locate 60,
Print BEF(BULNUM)
Pen WHITE
Print "Movement speed (0-5) :-";
Pen RED
Locate 60,
Print BMS(BULNUM)
Pen WHITE
Print "Impact Noise :-";
Pen RED
If ISFX(BULNUM)>0
Print SFX$(ISFX(BULNUM)-1)
Else
Locate 60, : Print "None"
End If
Pen RED
Centre "[ DEFINE BULLET ANIMATION ]"
Print
Pen RED
Centre "[ DEFINE IMPACT ANIMATION ]"
Locate 0,16 : Pen WHITE
Print "Bullet Graphic Type :-";
Pen RED
If BGT(BULNUM)=0
Print " Bitmap"
Else If BGT(BULNUM)=1
Print " Glare"
Else
Print " Additive Transparency"
End If
Locate 0,17 : Pen WHITE
Print "Impact Graphic Type :-";
Pen RED
If IGT(BULNUM)=0
Print " Bitmap"
Else If IGT(BULNUM)=1
Print " Glare"
Else
Print " Additive Transparency"
End If
Else
Print "INSTANT"
Print " "
Locate 0,15 : Pen RED : Centre "[ DEFINE IMPACT ANIMATION ]"
Locate 0,17 : Pen WHITE
Print "Impact Graphic Type :-";
Pen RED
If IGT(BULNUM)=0
Print " Bitmap"
Else If IGT(BULNUM)=1
Print " Glare"
Else
Print " Additive Transparency"
End If
End If
Return
BULDATSHOW:
Cls 0
Locate 0,0
Pen GREEN : Paper 0
Centre "Bullet Type List"
For A=0 To 19
Locate 5,A+1
Pen WHITE : Paper 0
Print A; : Locate 9, : Pen GREEN : Print "NAME:"; : Pen WHITE : Locate 15, : Print BULNAME$(A)
Next
Return
SETBACKSFX:
Menu Off
Repeat
Cls 0 : Locate 0,0
Pen GREEN
Centre "Select a number from 0-15 to choose background effects"
For A=0 To 15
Locate 0,A+2
Pen WHITE
Print A;
Locate 4,
Pen GREEN
Print SFX$(BACKSFX(A))
Next
Pen RED
Locate 0,31
Centre "*** DONE ***"
Repeat
Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)/8
If Y<>31
OOY=(Y-2)
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
If Y<>100
BACKSFX(OOY)=Y-1
End If
Y=1000
End If
Until Y=31
Cls 0
Menu On
Return
SETECHOSFX:
Menu Off
Repeat
Gosub SFXNAMESHOW
Locate 0,0 : Print Space$(80)
Locate 0,0
Pen GREEN
Centre "Select a Sound Effect :-"
For A=0 To 59
Y=(A mod 30)+1
X=(A/30)*40
Locate X+36,Y : Pen RED
Print ECHO(A)+1;
Next
Pen RED
Locate 0,31
Centre "*** DONE ***"
Gosub SFXNAMEPICK
If Y<>100
OOY=Y-1
Gosub SFXNAMESHOW
Locate 0,0 : Print Space$(80)
Locate 0,0
Pen RED
Centre "Select an echoed version of the sound :-"
Gosub SFXNAMEPICK
If Y<>100
ECHO(OOY)=Y-1
End If
Y=1000
End If
Until Y=100
Cls 0
Menu On
Return
PICKLEVELMUSIC:
Menu Off
Repeat
Cls 0 : Locate 0,0
Pen GREEN
Centre "Select a number from 0-15 to choose level music files"
For A=0 To 15
Locate 0,A+2
Pen WHITE
Print A;
Locate 4,
Pen GREEN
Print LEVMUSIC$(A)
Next
Pen RED
Locate 0,31
Centre "*** DONE ***"
Repeat
Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)/8
If Y<>31
Y=Y-2
If Y>=0 and Y<16
F$=Fsel$("","","Pick a PACKED music file")
LEVMUSIC$(Y)=F$
End If
End If
Until Y=31
Cls 0
Menu On
Return
SETSFXNAMES:
Menu Off
REDRAW=1
Repeat
If REDRAW=1
Gosub SFXNAMESHOW
REDRAW=0
End If
Pen RED : Paper 0
Locate 0,31
Centre "*** DONE ***"
Gosub SFXNAMEPICK
If Y>0 and Y<60
If MC=1
A$=Fsel$("","","Choose a RAW sample:")
If Exist(A$)
SFX$(Y-1)=A$
REDRAW=1
End If
End If
If MC=2
If Exist(SFX$(Y-1))
Open In 1,SFX$(Y-1)
L=Lof(1)
Close 1
Erase 14
Reserve As Chip Work 14,L
Bload SFX$(Y-1),Start(14)
Sam Raw $F,Start(14),L,8000
REDRAW=0
End If
End If
End If
Until Y>=100
Cls 0
Menu On
Return
SFXNAMEPICK:
Repeat
MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)
X=X Screen(0,X Mouse)
Y=Y/8
X=X/320
If Y>0 and Y<31
Y=Y+X*30
Else
If Y>30
Y=100
End If
End If
Return
SFXNAMESHOW:
Pen GREEN : Paper 0
Cls 0
Locate 0,0
Centre "SFX Filenames (Must be RAW format, half volume)"
Pen WHITE : Paper 0
For A=1 To 60
If A<31
Locate 0,A
Print A;
Locate 4, : Print SFX$(A-1)
End If
If A>30
Locate 40,A-30
Print A;
Locate 44, : Print SFX$(A-1)
End If
Next
Return
SETLEVELS:
Cls 0
Locate 0,0
F$=Fsel$("","","Pick a LEVELS directory")
F$=Dir$
Pen 2 : Paper 0
Print "Level directory set to ";
Pen 3 : Paper 0
Print F$
If Not(Exist(F$+"level_a"))
Pen 1 : Paper 0
Print "Create Level directories A-P (Y/N)?"
Input A$
If A$="y" or A$="Y"
Pen 3 : Paper 0
For A=Asc("A") To Asc("P")
B$=Chr$(A)
Mkdir F$+"LEVEL_"+B$
Print F$+"LEVEL_"+B$+" created"
Next
LEVELDIR$=F$
End If
Else
LEVELDIR$=F$
End If
Return
'
SETLEVELNAMES:
Menu Off
Cls 0
Locate 0,0
Pen 3 : Paper 0
Print " |------------------**------------------|"
Pen 2 : Paper 0
For A=0 To 15
Print " ";LEVNAME$(A)
Next
Pen 1 : Paper 0
Print " *** DONE *** "
Repeat
Repeat
Until Mouse Click=1
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y>0 and Y<17
Pen 1 : Paper 0
Locate 0,Y : Print Space$(42)
Locate 0,Y : Input A$
If Len(A$)<40
A$=A$+Space$(40-Len(A$))
End If
If Len(A$)>40
A$=Left$(A$,40)
End If
Locate 0,Y : LEVNAME$(Y-1)=A$ : Print Space$(79)
Locate 0,Y : Pen 2 : Paper 0 : Print " ";LEVNAME$(Y-1)
End If
Until Y=17
Cls 0
Locate 0,0
Menu On
Return
SETOBJGFXNAMES:
Menu Off
Y=0
Repeat
Gosub PICKOBJGRAPHNAME
If Y>0 and Y<=(TGR+1)
If MC=1 or Not(Exist(OBJGFX$(Y-1)+".wad"))
A$="OBJECT GFX #"+Str$(Y)
A$=Fsel$("","",A$)
A$=Upper$(A$)
If A$="DELETE" and Y=TGR
OBJGFX$(Y-1)=""
Else
If Exist(A$)
OBJGFX$(Y-1)=Left$(A$,Len(A$)-4)
End If
End If
Locate 0,Y : Print Space$(79)
Locate 0,Y : Pen 2 : Paper 0 : Print Y; : Locate 4, : Print OBJGFX$(Y-1)
Else
Gosub SETOBJFRAMES
End If
End If
Until Y=31
Cls 0
Locate 0,0
Menu On
Return
SETVECTORNAMES:
Menu Off
Y=0
Repeat
Gosub PICKVECTORNAME
If Y>0 and Y<=(TGR+1)
If MC=1 or Not(Exist(VECGFX$(Y-1)+".dat"))
A$="VECTOR GFX #"+Str$(Y)
A$=Fsel$("","",A$)
A$=Upper$(A$)
If A$="DELETE" and Y=TGR
VECGFX$(Y-1)=""
Else
If Exist(A$)
VECGFX$(Y-1)=A$
End If
End If
Locate 0,Y : Print Space$(79)
Locate 0,Y : Pen 2 : Paper 0 : Print Y; : Locate 4, : Print VECGFX$(Y-1)
End If
End If
Until Y=31
Cls 0
Locate 0,0
Menu On
Return
VECTORNAMESHOW:
Cls 0
Locate 0,0
Pen 3 : Paper 0
Centre "Vector GFX Filenames"
Locate 0,1
Pen 2 : Paper 0
TGR=0
A=0
Repeat
A$=Str$(A+1)
Print A$; : Locate 4, : Print VECGFX$(A)
If VECGFX$(A)<>"" and TGR<29 Then TGR=TGR+1
A=A+1
Until A>TGR
Return
PICKVECTORNAME:
Gosub VECTORNAMESHOW
Pen 1 : Paper 0
Locate 0,31
Centre "DONE"
Repeat
MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)
Y=Y/8
Return
SETWALLNAMES:
Menu Off
Y=0
Repeat
Gosub PICKWALLNAME
If Y>0 and Y<=(TGR+1)
If MC=1
A$="WALL GFX #"+Str$(Y)
A$=Fsel$("","",A$)
A$=Upper$(A$)
If Exist(A$)
WALLGFX$(Y-1)=A$
Open In 1,A$
T=Lof(1)
Close 1
Bload A$,Start(15)
WALLHEIGHT(Y-1)=Deek(Start(15)+T-2)
End If
Locate 0,Y : Print Space$(79)
Locate 0,Y : Pen 2 : Paper 0 : Print Y; : Locate 4, : Print WALLGFX$(Y-1)
Else
If MC=2 and Y=TGR
WALLGFX$(Y-1)=""
End If
End If
End If
Until Y=31
Cls 0
Locate 0,0
Menu On
Return
WALLNAMESHOW:
Cls 0
Locate 0,0
Pen 3 : Paper 0
Centre "Wall GFX Filenames"
Locate 0,1
Pen 2 : Paper 0
TGR=0
A=0
Repeat
A$=Str$(A+1)
Print A$; : Locate 4, : Print WALLGFX$(A)
If WALLGFX$(A)<>"" and TGR<15 Then TGR=TGR+1
A=A+1
Until A>TGR
Return
PICKWALLNAME:
Gosub WALLNAMESHOW
Pen 1 : Paper 0
Locate 0,31
Centre "DONE"
Repeat
MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)
Y=Y/8
Return
SETOBJFRAMES:
Screen Open 1,320,256,32,Lowres
Curs Off : Flash Off : Cls 0
If Not Exist(OBJGFX$(Y-1)+".256pal")
Screen 0 : Cls 0 : Screen To Front 0
Locate 0,10 : Pen RED : Centre "Palette file not found."
Locate 0,12 : Centre "Error in loading: please select a different graphic file."
Locate 0,14 : Pen GREEN : Centre "Any key to return to editor."
Wait Key
Return
End If
Bload OBJGFX$(Y-1)+".256pal",Start(15)
Bload "ab3:includes/256pal",Start(15)+1024
For A=0 To 31 :
C=Peek(Start(15)+A*2)
R=Deek(Start(15)+1024+C*6)
G=Deek(Start(15)+1026+C*6)
B=Deek(Start(15)+1028+C*6)
Colour A,(R/16)*$100+(G/16)*$10+(B/16)
Next
LIT=0
If Exist(OBJGFX$(Y-1)+".HQN")
Bload OBJGFX$(Y-1)+".HQN",Start(15)
LIT=1
Else
Bload OBJGFX$(Y-1)+".dat",Start(15)
End If
XOF=0
Gosub WIDTHSHOW
Screen 0 : Screen To Front 0 : Screen Display 0,,42+140,,
Cls 0
CF=0
Gosub FRAMEDISPLAY
EX=0
Repeat
Repeat
LY=Y Screen(1,Y Mouse)
LX=X Screen(1,X Mouse)
If(LY<HOF) and(LX+XOF<NO*WOF)
Screen 0 : Locate 0,0 : Pen WHITE : Wait Vbl : Print Using "X :###";LX; Using " Y :###";LY;
End If
Until Mouse Click<>0
LY=Y Screen(1,Y Mouse)
LX=X Screen(1,X Mouse)
If LY>140
LY=(LY-140)/8
LX=LX/8
If LY=13
EX=1
End If
If LY=0
If LX<28 and XOF>0
Add XOF,-160
Gosub WIDTHSHOW
Else
If LX>28 and(XOF+319)<(WOF*NO)
Add XOF,160
Gosub WIDTHSHOW
End If
End If
End If
If LY=2
If LX>20 and LX<29
CF=Max(CF-1,0)
Gosub FRAMEDISPLAY
End If
If LX>29
CF=Min(63,CF+1)
Gosub FRAMEDISPLAY
End If
End If
If LY=4
Screen 0
Locate 15,4
Input O
OGFRAMES(Y-1,CF,0)=O and $FFFF
Gosub FRAMEDISPLAY
End If
If LY=5
Screen 0
Locate 15,5
Input O
OGFRAMES(Y-1,CF,1)=O and $FFFF
Gosub FRAMEDISPLAY
End If
If LY=6
Screen 0
Locate 15,6
Input O
OGFRAMES(Y-1,CF,2)=O and $FFFE
Gosub FRAMEDISPLAY
End If
If LY=7
Screen 0
Locate 15,7
Input O
OGFRAMES(Y-1,CF,3)=O and $FFFE
Gosub FRAMEDISPLAY
End If
If LY=9
If LX<20 and CF>0
For A=0 To CF-1
OGFRAMES(Y-1,A,2)=OGFRAMES(Y-1,CF,2)
Next
Else
If CF<63
For A=CF+1 To 63
OGFRAMES(Y-1,A,2)=OGFRAMES(Y-1,CF,2)
Next
End If
End If
End If
If LY=10
If LX<20 and CF>0
For A=0 To CF-1
OGFRAMES(Y-1,A,3)=OGFRAMES(Y-1,CF,3)
Next
Else
If CF<63
For A=CF+1 To 63
OGFRAMES(Y-1,A,3)=OGFRAMES(Y-1,CF,3)
Next
End If
End If
End If
If LY=11
For A=0 To NO-1
OGFRAMES(Y-1,A,0)=A*WOF
OGFRAMES(Y-1,A,1)=0
OGFRAMES(Y-1,A,2)=WOF
OGFRAMES(Y-1,A,3)=HOF
Next
Gosub FRAMEDISPLAY
End If
Else
If(LY<HOF) and(LX+XOF<NO*WOF)
OGFRAMES(Y-1,CF,0)=LX : OGFRAMES(Y-1,CF,1)=LY : Gosub FRAMEDISPLAY
End If
End If
Until EX=1
Screen Close 1
Screen 0
Rainbow 1,0,0,0
Screen Display 0,,42,,
Return
FRAMEDISPLAY:
Cls 0
Paper 0 : Pen RED
Locate 40,0 : Print "[ SCROLL LEFT ] [ SCROLL RIGHT ]"
Locate 0,2 : Pen GREEN : Print "Frame number : "; : Pen WHITE : Print CF
Locate 40,2 : Pen RED : Print "[ PREVIOUS FRAME ] [ NEXT FRAME ]"
Locate 0,4 : Pen GREEN : Print "Frame left : "; : Pen RED : Print OGFRAMES(Y-1,CF,0)
Locate 0,5 : Pen GREEN : Print "Frame top : "; : Pen RED : Print OGFRAMES(Y-1,CF,1)
Locate 0,6 : Pen GREEN : Print "Frame width : "; : Pen RED : Print OGFRAMES(Y-1,CF,2)
Locate 0,7 : Pen GREEN : Print "Frame height : "; : Pen RED : Print OGFRAMES(Y-1,CF,3)
Locate 0,9 : Pen RED : Centre "[ Copy width to previous frames ][ Copy width to subsequent frames ]"
Locate 0,10 : Pen RED : Centre "[ Copy height to previous frames ][ Copy height to subsequent frames ]"
Locate 0,11 : Pen GREEN : Centre "[ Generate frames from graphic data ]"
Locate 0,13 : Pen RED : Centre "*** DONE ***"
Return
WIDTHSHOW:
SC=Screen : Screen 1
Cls 0
S=Start(15)+6+(HOF*XOF)
NO=Deek(Start(15))
WOF=Deek(Start(15)+2)
HOF=Deek(Start(15)+4)
M$="("+(Str$(HOF)-" ")+",0,1)(1,15,1)("+(Str$(Max(1,(140-HOF)/15))-" ")+",-1,15)"
Set Rainbow 1,0,256,M$,M$,M$
Rainbow 1,0,42,140
RX=Min(319,(WOF*NO-1)-XOF)
For X=0 To RX
For L=0 To HOF-1
Extension_12_036E X,L,Peek(S) : Add S,1
Next
Next
Screen SC
Return
OBJGRAPHNAMESHOW:
Cls 0
Locate 0,0
Pen 3 : Paper 0
Centre "Object GFX Filenames"
Locate 0,1
Pen 2 : Paper 0
TGR=0
A=0
Repeat
A$=Str$(A+1)
Print A$; : Locate 4, : Print OBJGFX$(A)
If OBJGFX$(A)<>"" and TGR<29 Then TGR=TGR+1
A=A+1
Until A>TGR
Return
PICKOBJGRAPHNAME:
Gosub OBJGRAPHNAMESHOW
Pen 1 : Paper 0
Locate 0,31
Centre "DONE"
Repeat
MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)
Y=Y/8
Return
SETFLOORTILENAME:
T$="Floor Tile"
Gosub TEXNAMEGET
If BACK$<>"" Then FTMNAME$=BACK$
Return
SETTEXNAME:
T$="Texture"
Gosub TEXNAMEGET
If BACK$<>"" Then TEXNAME$=BACK$
Return
TEXNAMEGET:
Cls 0
Locate 0,0
BACK$=""
A$=Fsel$("","","Select a texture file")
A$=Upper$(A$)
If Exist(A$)
Open In 1,A$
Pen WHITE : Paper 0
Print T$;" filename set to ";
Pen GREEN : Paper 0
Print A$
BACK$=A$
Close 1
Else
Pen RED : Paper 0
Print "FILE NOT FOUND"
End If
Return
SETGUNGFXNAME:
Cls 0
Locate 0,0
A$=Fsel$("","","Select a .ODF file")
A$=Upper$(A$)
If Exist(A$)
Pen WHITE : Paper 0
Print "Gun Graphics filename set to ";
Pen GREEN : Paper 0
Print A$
FTMNAME$=A$
Else
Pen RED : Paper 0
Print "FILE NOT FOUND"
End If
Return
SETALIENNAME:
Menu Off
Repeat
Gosub ALIENNAMESHOW
Repeat : MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)/8
X=X Screen(0,X Mouse)/8
Y=Y-1
If Y>=0 and Y<=ALMAX
If X<40
Locate 4,Y+1 : Pen RED : Input ALNAME$(Y)
Else If X<70
Gosub SETALIENSTATS
Else
OY=Y
Pen GREEN : Locate 0,30 : Print "Select space to copy to:"
Repeat : MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)/8
X=X Screen(0,X Mouse)/8
Y=Y-1
If Y>=0 and Y<=ALMAX
ALNAME$(Y)=ALNAME$(OY)
ALBRIGHT(Y)=ALBRIGHT(OY)
For A=0 To 19
ALSTAT(Y,A)=ALSTAT(OY,A)
For B=0 To 10 : For C=0 To 10
ALANIM(Y,B,A,C)=ALANIM(OY,B,A,C)
Next
Next
Next
ALSTAT(Y,20)=ALSTAT(OY,20)
End If
End If
End If
If Y=28
Locate 0,29 : Pen GREEN : Print Space$(80);
Locate 0,29 : Centre "Select alien to scale:"
Repeat : Until Mouse Click
F=Y Screen(0,Y Mouse)/8
If F>0 and F<=ALMAX+1
F=F-1
Locate 0,29 : Input "New percentage of original size: ";P
For A=0 To 10
For B=0 To 19
ALANIM(F,A,B,2)=(ALANIM(F,A,B,2)*P)/100
ALANIM(F,A,B,3)=(ALANIM(F,A,B,3)*P)/100
ALANIM(F,A,B,4)=(ALANIM(F,A,B,4)*P)/100
ALANIM(F,A,B,9)=(ALANIM(F,A,B,9)*P)/100
ALANIM(F,A,B,10)=(ALANIM(F,A,B,10)*P)/100
Next
Next
ALSTAT(F,17)=(ALSTAT(F,17)*P)/100
End If
End If
Until Y=30
Cls 0
Menu On
Return
SETALIENSTATS:
AN=Y
Repeat
Gosub ALIENSTATSHOW
Repeat : MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)/8
If Y=1
ALSTAT(AN,0)=(ALSTAT(AN,0)+1) mod 6
End If
If Y=3
If ALSTAT(AN,0)<>1
Gosub DEFALIENANIM
Else
Gosub DEFALIENVECTORANIM
End If
End If
If Y=ZED
If MC=1
Add ALSTAT(AN,1),1
If DEFB$(ALSTAT(AN,1))=""
ALSTAT(AN,1)=0
End If
Else
Add ALSTAT(AN,1),-1
If ALSTAT(AN,1)=-1
ALSTAT(AN,1)=10
Repeat
Add ALSTAT(AN,1),-1
Until DEFB$(ALSTAT(AN,1))<>""
End If
End If
End If
If(Y=ZED+1 or Y=ZED+2) or(Y>=ZED+4 and Y<=ZED+7) or(Y=ZED+9 or Y=ZED+10) or(Y=ZED+12 or Y=ZED+13)
Locate 40,Y : Pen RED : Input ALSTAT(AN,(Y-ZED)+1)
End If
If Y=ZED+3
If MC=1
Add ALSTAT(AN,4),1
If RESB$(ALSTAT(AN,4))=""
ALSTAT(AN,4)=0
End If
Else
Add ALSTAT(AN,4),-1
If ALSTAT(AN,4)=-1
ALSTAT(AN,4)=10
Repeat
Add ALSTAT(AN,4),-1
Until RESB$(ALSTAT(AN,4))<>""
End If
End If
End If
If Y=ZED+8
If MC=1
Add ALSTAT(AN,9),1
If FOLB$(ALSTAT(AN,9))=""
ALSTAT(AN,9)=0
End If
Else
Add ALSTAT(AN,9),-1
If ALSTAT(AN,9)=-1
ALSTAT(AN,9)=10
Repeat
Add ALSTAT(AN,9),-1
Until FOLB$(ALSTAT(AN,9))<>""
End If
End If
End If
If Y=ZED+11
If MC=1
Add ALSTAT(AN,12),1
If RETB$(ALSTAT(AN,12))=""
ALSTAT(AN,12)=0
End If
Else
Add ALSTAT(AN,12),-1
If ALSTAT(AN,12)=-1
ALSTAT(AN,12)=10
Repeat
Add ALSTAT(AN,12),-1
Until RETB$(ALSTAT(AN,12))<>""
End If
End If
End If
If Y=ZED+14
DN=0
While DN=0
Gosub BULDATSHOW
Locate 0,30
Pen RED : Centre "[ Select Alien to Spawn Instead ]"
Repeat
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
Until(F>0 and F<21) or F=30
If F=30
Gosub ALIENNAMESHOW
Ink 0 : Bar 320,8 To 640,240
Pen RED : Locate 0,30
Centre "[ Select Bullet to Fire Instead ]"
Repeat
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
Until(F>0 and F<21) or F=30
If F<>30 : DN=1 : F=F+20 : End If
Else
DN=1
End If
Wend
ALSTAT(AN,15)=F-1
End If
If Y=ZED+15
Locate 40,Y : Ink RED : Input ALS : ALSTAT(AN,16)=ALS/4
End If
If Y=ZED+16
Locate 40,Y : Ink RED : Input ALSTAT(AN,17)
End If
If Y=ZED+17
Locate 40,Y : Ink RED : Input ALSTAT(AN,18)
End If
If Y=ZED+18
DN=0
While DN=0
Gosub BULDATSHOW
Locate 0,30
Pen RED : Centre "[ Select Alien to Spawn Instead ]"
Repeat
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
Until(F>0 and F<21) or F=30
If F=30
Gosub ALIENNAMESHOW
Ink 0 : Bar 320,8 To 640,240
Pen RED : Locate 0,30
Centre "[ Select Projectile Instead ]"
Repeat
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
Until(F>0 and F<21) or F=30
If F<>30 : DN=1 : F=F+20 : End If
Else
DN=1
End If
Wend
ALSTAT(AN,19)=F-1
End If
If Y=ZED+19
Gosub OBJNAMESHOW
Repeat
Until Mouse Click
F=Y Screen(0,Y Mouse)
F=F/8
ALSTAT(AN,20)=F-1
End If
If Y=ZED+20
Locate 40,ZED+20
Pen RED
Input ALBRIGHT(AN)
End If
If Y=ZED+21
Locate 40,ZED+21
Pen RED
Input ALSHOTXOFF(AN)
End If
If Y=ZED+22
Locate 40,ZED+22
Pen RED
Input ALSHOTYOFF(AN)
End If
Until Y=31
Return
ALIENSTATSHOW:
Cls 0
Locate 0,0 : Pen GREEN
Centre "Characteristics of alien :"+ALNAME$(AN)
Locate 0,1 : Pen WHITE
Print "Graphic type: :"
Locate 40,1 : Pen RED
Print GFXTYPE$(ALSTAT(AN,0))
Locate 0,3 : Pen RED
Centre "[ Define Animation Frames ]"
ZED=4 : Locate 0,ZED : Pen WHITE
Print "Default Behaviour :"
Locate 40,ZED : Pen GREEN
Print DEFB$(ALSTAT(AN,1))
Locate 0,ZED+1 : Pen WHITE
Print "Reaction Time (50=1sec) :"
Locate 40,ZED+1 : Pen GREEN
Print ALSTAT(AN,2)
Locate 0,ZED+2 : Pen WHITE
Print "Default movement speed :"
Locate 40,ZED+2 : Pen GREEN
Print ALSTAT(AN,3)
Locate 0,ZED+3 : Pen WHITE
Print "Response Behaviour :"
Locate 40,ZED+3 : Pen GREEN
Print RESB$(ALSTAT(AN,4))
Locate 0,ZED+4 : Pen WHITE
Print "Response movement speed :"
Locate 40,ZED+4 : Pen GREEN
Print ALSTAT(AN,5)
Locate 0,ZED+5 : Pen WHITE
Print "Response Timeout (50=1sec) :"
Locate 40,ZED+5 : Pen GREEN
Print ALSTAT(AN,6)
Locate 0,ZED+6 : Pen WHITE
Print "Damage Taken Limit -> Retreat :"
Locate 40,ZED+6 : Pen GREEN
Print ALSTAT(AN,7)
Locate 0,ZED+7 : Pen WHITE
Print "Damage Inflicted Limit -> Followup :"
Locate 40,ZED+7 : Pen GREEN
Print ALSTAT(AN,8)
Locate 0,ZED+8 : Pen WHITE
Print "Followup Behaviour :"
Locate 40,ZED+8 : Pen GREEN
Print FOLB$(ALSTAT(AN,9))
Locate 0,ZED+9 : Pen WHITE
Print "Followup Movement Speed :"
Locate 40,ZED+9 : Pen GREEN
Print ALSTAT(AN,10)
Locate 0,ZED+10 : Pen WHITE
Print "Followup Timeout (50=1sec) :"
Locate 40,ZED+10 : Pen GREEN
Print ALSTAT(AN,11)
Locate 0,ZED+11 : Pen WHITE
Print "Retreat Behaviour :"
Locate 40,ZED+11 : Pen GREEN
Print RETB$(ALSTAT(AN,12))
Locate 0,ZED+12 : Pen WHITE
Print "Retreat Movement Speed :"
Locate 40,ZED+12 : Pen GREEN
Print ALSTAT(AN,13)
Locate 0,ZED+13 : Pen WHITE
Print "Retreat Timeout (50=1sec) :"
Locate 40,ZED+13 : Pen GREEN
Print ALSTAT(AN,14)
Locate 0,ZED+14 : Pen WHITE
If ALSTAT(AN,15)<20
Print "Type Of Bullet Fired :"
Locate 40,ZED+14 : Pen GREEN
Print BULNAME$(ALSTAT(AN,15))
Else
Print "Type Of Alien Spawned :"
Locate 40,ZED+14 : Pen GREEN
Print ALNAME$(ALSTAT(AN,15)-20)
End If
Locate 0,ZED+15 : Pen WHITE
Print "Number Of Hit Points :"
Locate 40,ZED+15 : Pen GREEN
Print ALSTAT(AN,16)*4
Locate 0,ZED+16 : Pen WHITE
Print "Physical Height :"
Locate 40,ZED+16 : Pen GREEN
Print ALSTAT(AN,17)
Locate 0,ZED+17 : Pen WHITE
Print "Minimum distance to walls (0/1/2) :"
Locate 40,ZED+17 : Pen GREEN
Print ALSTAT(AN,18)
Locate 0,ZED+18 : Pen WHITE
If ALSTAT(AN,19)<20
Print "Projectiles ejected upon death :"
Locate 40,ZED+18 : Pen GREEN
Print BULNAME$(ALSTAT(AN,19))
Else
Print "Aliens spawned upon death :"
Locate 40,ZED+18 : Pen GREEN
Print ALNAME$(ALSTAT(AN,19)-20)
End If
Locate 0,ZED+19 : Pen WHITE
Print "Auxilliary Object Type: :"
Locate 40,ZED+19 : Pen GREEN
If ALSTAT(AN,20)>=0
Print OBNAME$(ALSTAT(AN,20))
Else
Print "None."
End If
Locate 0,ZED+20 : Pen WHITE
Print "Torch Brightness :"
Locate 40,ZED+20 : Pen GREEN
Print ALBRIGHT(AN)
Locate 0,ZED+21 : Pen WHITE
Print "Bullet Source X Offset :"
Locate 40,ZED+21 : Pen GREEN
Print ALSHOTXOFF(AN)
Locate 0,ZED+22 : Pen WHITE
Print "Bullet Source Y Offset :"
Locate 40,ZED+22 : Pen GREEN
Print ALSHOTYOFF(AN)
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Return
DEFALIENANIM:
Repeat
Gosub SUBSETSHOW
Repeat : Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y=2
OP=0 : M$="Front Facing Movement"
Gosub DEFALAN
End If
If Y=4
OP=1 : M$="Front-Right Facing Movement"
Gosub DEFALAN
End If
If Y=6
OP=2 : M$="Right Facing Movement"
Gosub DEFALAN
End If
If Y=8
OP=3 : M$="Back-Right Facing Movement"
Gosub DEFALAN
End If
If Y=10
OP=4 : M$="Back Facing Movement"
Gosub DEFALAN
End If
If Y=12
OP=5 : M$="Back-Left Facing Movement"
Gosub DEFALAN
End If
If Y=14
OP=6 : M$="Left Facing Movement"
Gosub DEFALAN
End If
If Y=16
OP=7 : M$="Front-Left Facing Movement"
Gosub DEFALAN
End If
If Y=18
OP=8 : M$="Attacking Action"
Gosub DEFALAN
End If
If Y=20
OP=9 : M$="Recieving Damage Action"
Gosub DEFALAN
End If
If Y=22
OP=10 : M$="Dying Action"
Gosub DEFALAN
End If
If Y=29
Locate 0,31 : Pen GREEN : Centre " SELECT ANIM TO COPY FROM "
Repeat
Until Mouse Click<>0
F=Y Screen(0,Y Mouse)/16
If F>0 and F<12
OF=F-1
Locate 0,31 : Pen GREEN : Centre " SELECT ANIM TO COPY TO "
Repeat
Until Mouse Click<>0
F=Y Screen(0,Y Mouse)/16
If F>0 and F<12
F=F-1
For A=0 To 19 : For B=0 To 10
ALANIM(AN,F,A,B)=ALANIM(AN,OF,A,B)
Next : Next
End If
End If
End If
Until Y=31
Y=0
Return
ALANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Animation frames for "+ALNAME$(AN)+" "+M$
Centre A$
'Locate 40,0
'Pen WHITE
'Print "Frame Width:"
'Locate 53,0
'Pen RED
'Print Using "###";BFW(BULNUM)
'Locate 60,0
'Pen WHITE
'Print "Frame Height:"
'Locate 74,0
'Pen RED
'Print Using "###";BFH(BULNUM)
A=-1
Repeat
Add A,1
If ALANIM(AN,OP,A,0)>-1
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print Using "## ";A;
Print "GF:";
Pen RED
Print Using "## ";ALANIM(AN,OP,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
If ALANIM(AN,OP,A,1)<0
Print "R";
Else
Print " ";
End If
Print Using "##";Abs(ALANIM(AN,OP,A,1));
Pen WHITE
Print "SW:";
Pen RED
Print Using "### ";ALANIM(AN,OP,A,2);
Pen WHITE
Print "SH:";
Pen RED
Print Using "### ";ALANIM(AN,OP,A,3);
Pen WHITE
Print "VO:";
Pen RED
Print Using "+## ";ALANIM(AN,OP,A,4);
Pen WHITE
Print "FX:";
Pen RED
Print Using "## ";ALANIM(AN,OP,A,5);
Pen WHITE
Print "AC:";
Pen RED
If ALANIM(AN,OP,A,6)=1
Print " * ";
Else
Print " ";
End If
Pen WHITE
Print "AI:";
Pen RED
A7=ALANIM(AN,OP,A,7)
If A7=0
Print " v ";
Else If A7/64=1
Print "S"; Using "##";A7 and 63;
Else If A7/64=2
Print "R"; Using "##";A7 and 63;
Else
Print "D"; Using "##";A7 and 63;
End If
Pen WHITE
Print "AUX:";
Pen RED
If ALANIM(AN,OP,A,8)>=0
Print Using "##";ALANIM(AN,OP,A,8);
Else
Print " ";
End If
Pen WHITE
Print "XO:";
Pen RED
Print Using "+###";ALANIM(AN,OP,A,9)*2;
Pen WHITE
Print "YO:";
Pen RED
Print Using "+###";ALANIM(AN,OP,A,10)*2;
Print
End If
Until ALANIM(AN,OP,A,0)<0 or A=19
AMAX=A-1
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
DEFALAN:
Repeat
Gosub ALANIMSHOW
Repeat
MC=Mouse Click
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
Until MC<>0
If Y=31
If X<15
If AMAX<19
Add AMAX,1
For J=0 To 10
ALANIM(AN,OP,AMAX,J)=ALANIM(AN,OP,AMAX-1,J)
Next
End If
Else
If X<30 and AMAX>0
Add AMAX,-1
ALANIM(AN,OP,AMAX+1,0)=-1
End If
End If
End If
Z=(Y-1)
DX=X-3
' If Y=0
' If X>40 and X<60
' Pen GREEN
' Locate 0,31 : Input "FRAME WIDTH :";BFW(BULNUM);
' End If
' If X>60
' Pen GREEN
' Locate 0,31 : Input "FRAME HEIGHT :";BFH(BULNUM);
' End If
' End If
If Y>0 and Y<=AMAX+1
If DX>2 and DX<6
Gosub PICKOBJGRAPHNAME
ALANIM(AN,OP,Z,0)=Y-1
End If
If DX>8 and DX<12
If MC=2
FRAMEPICK[ALANIM(AN,OP,Z,0),ALANIM(AN,OP,Z,1)]
ALANIM(AN,OP,Z,1)=Param
Gosub ALANIMSHOW
Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";ALANIM(AN,OP,Z,1);
End If
End If
If DX>14 and DX<19
Pen GREEN
Locate 0,31 : Input "SCALED WIDTH :";ALANIM(AN,OP,Z,2);
End If
If DX>21 and DX<26
Pen GREEN
Locate 0,31 : Input "SCALED HEIGHT :";ALANIM(AN,OP,Z,3);
End If
If DX>28 and DX<33
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";ALANIM(AN,OP,Z,4);
End If
If DX>35 and DX<39
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
ALANIM(AN,OP,Z,5)=Y
End If
If DX>41 and DX<45
ALANIM(AN,OP,Z,6)=1-ALANIM(AN,OP,Z,6)
End If
If DX>47 and DX<51
Pen GREEN
Locate 0,31
Input "(S)tore val, Add (R)andom val, (D)ecrement and branch:";A$
A$=Upper$(A$)
If A$="S"
Locate 0,31
Input "Value to store in counter (0-63): ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),64
Else If A$="R"
Locate 0,31
Input "Max. random value to add (0-63): ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),128
Else If A$="D"
Locate 0,31
Input "Frame to branch to when count reaches zero: ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),192
Else
ALANIM(AN,OP,Z,7)=0
End If
End If
If DX>54 and DX<57
NO=ALSTAT(AN,20) : Gosub OBDEFANIMSHOW
Repeat : Until Mouse Click
F=Y Screen(0,Y Mouse) : F=F/8
ALANIM(AN,OP,Z,8)=F-1
End If
If DX>59 and DX<64
Pen GREEN : Locate 0,31 : Input "Horizontal offset of auxilliary frame: ";QAW
ALANIM(AN,OP,Z,9)=QAW/2
End If
If DX>66 and DX<72
Pen GREEN : Locate 0,31 : Input "Vertical offset of auxilliary frame: ";QAW
ALANIM(AN,OP,Z,10)=QAW/2
End If
End If
Until Y=31 and X>60
Y=0
Return
SUBSETSHOW:
Cls 0 : Locate 0,0
Pen GREEN
Centre "Subsets of animation frames for "+ALNAME$(AN)
Pen RED
Locate 0,2
Centre "[ Front Facing Movement ]"
Locate 0,4
Centre "[ Front-Right Facing Movement ]"
Locate 0,6
Centre "[ Right Facing Movement ]"
Locate 0,8
Centre "[ Back-Right Facing Movement ]"
Locate 0,10
Centre "[ Back Facing Movement ]"
Locate 0,12
Centre "[ Back-Left Facing Movement ]"
Locate 0,14
Centre "[ Left-Facing Movement ]"
Locate 0,16
Centre "[ Front-Left Facing Movement ]"
Locate 0,18
Centre "[ Attacking Action ]"
Locate 0,20
Centre "[ Recieving Damage Action ]"
Locate 0,22
Centre "[ Dying Action ]"
Locate 0,29
Centre "[ Copy Action Animation Frames ]"
Locate 0,31
Centre "*** DONE ***"
Return
DEFALIENVECTORANIM:
Repeat
Gosub VECTORSUBSETSHOW
Repeat : Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)
Y=Y/8
If Y=2
OP=0 : M$="Movement"
Gosub DEFALANVEC
End If
If Y=18
OP=8 : M$="Attacking Action"
Gosub DEFALANVEC
End If
If Y=20
OP=9 : M$="Recieving Damage Action"
Gosub DEFALANVEC
End If
If Y=22
OP=10 : M$="Dying Action"
Gosub DEFALANVEC
End If
Until Y=31
Y=0
Return
VECTORSUBSETSHOW:
Cls 0 : Locate 0,0
Pen GREEN
Centre "Subsets of animation frames for "+ALNAME$(AN)
Pen RED
Locate 0,2
Centre "[ Movement ]"
Locate 0,18
Centre "[ Attacking Action ]"
Locate 0,20
Centre "[ Recieving Damage Action ]"
Locate 0,22
Centre "[ Dying Action ]"
Locate 0,31
Centre "*** DONE ***"
Return
ALANIMVECSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Vector Animation frames for "+ALNAME$(AN)+" "+M$
Centre A$
'Locate 40,0
'Pen WHITE
'Print "Frame Width:"
'Locate 53,0
'Pen RED
'Print Using "###";BFW(BULNUM)
'Locate 60,0
'Pen WHITE
'Print "Frame Height:"
'Locate 74,0
'Pen RED
'Print Using "###";BFH(BULNUM)
A=-1
Repeat
Add A,1
If ALANIM(AN,OP,A,0)>-1
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print Using "## ";A;
Print "GF:";
Pen RED
Print Using "## ";ALANIM(AN,OP,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";ALANIM(AN,OP,A,1);
Pen WHITE
Print "AO:";
Pen RED
Print Using "####";(ALANIM(AN,OP,A,2)*256+ALANIM(AN,OP,A,3)) and 8190;
Print " ";
Print "VO:";
Pen RED
Print Using "+## ";ALANIM(AN,OP,A,4);
Pen WHITE
Print "FX:";
Pen RED
Print Using "## ";ALANIM(AN,OP,A,5);
Pen WHITE
Print "AC:";
Pen RED
If ALANIM(AN,OP,A,6)=1
Print " * ";
Else
Print " ";
End If
Pen WHITE
Print "AI:";
Pen RED
A7=ALANIM(AN,OP,A,7)
If A7=0
Print " v ";
Else If A7/64=1
Print "S"; Using "##";A7 and 63;
Else If A7/64=2
Print "R"; Using "##";A7 and 63;
Else
Print "D"; Using "##";A7 and 63;
End If
Pen WHITE
Print "AUX:";
Pen RED
If ALANIM(AN,OP,A,8)>=0
Print Using "##";ALANIM(AN,OP,A,8);
Else
Print " ";
End If
Pen WHITE
Print "XO:";
Pen RED
Print Using "+###";ALANIM(AN,OP,A,9)*2;
Pen WHITE
Print "YO:";
Pen RED
Print Using "+###";ALANIM(AN,OP,A,10)*2;
Print
End If
Until ALANIM(AN,OP,A,0)<0 or A=19
AMAX=A-1
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
DEFALANVEC:
Repeat
Gosub ALANIMVECSHOW
Repeat
MC=Mouse Click
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
Until MC<>0
If Y=31
If X<15
If AMAX<19
Add AMAX,1
For J=0 To 10
ALANIM(AN,OP,AMAX,J)=ALANIM(AN,OP,AMAX-1,J)
Next
End If
Else
If X<30 and AMAX>0
Add AMAX,-1
ALANIM(AN,OP,AMAX+1,0)=-1
End If
End If
End If
Z=(Y-1)
DX=X-3
If Y>0 and Y<=AMAX+1
If DX>2 and DX<6
Gosub PICKVECTORNAME
ALANIM(AN,OP,Z,0)=Y-1
End If
If DX>8 and DX<12
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";ALANIM(AN,OP,Z,1);
End If
If DX>14 and DX<19
Locate 0,31 : Input "Facing Angle :";AL : ALANIM(AN,OP,Z,2)=(AL and 8190)/256
ALANIM(AN,OP,Z,3)=AL and $FE
End If
If DX>28 and DX<33
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";ALANIM(AN,OP,Z,4);
End If
If DX>35 and DX<39
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
ALANIM(AN,OP,Z,5)=Y
End If
If DX>41 and DX<45
ALANIM(AN,OP,Z,6)=1-ALANIM(AN,OP,Z,6)
End If
If DX>47 and DX<51
Pen GREEN
Locate 0,31
Input "(S)tore val, Add (R)andom val, (D)ecrement and branch:";A$
A$=Upper$(A$)
If A$="S"
Locate 0,31
Input "Value to store in counter (0-63): ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),64
Else If A$="R"
Locate 0,31
Input "Max. random value to add (0-63): ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),128
Else If A$="D"
Locate 0,31
Input "Frame to branch to when count reaches zero: ";ALANIM(AN,OP,Z,7)
Add ALANIM(AN,OP,Z,7),192
Else
ALANIM(AN,OP,Z,7)=0
End If
End If
If DX>55 and DX<58
OB=ALSTAT(AN,20) : Gosub OBDEFANIMSHOW
Repeat : Until Mouse Click
F=Y Screen(0,Y Mouse) : F=F/8
ALANIM(AN,OP,Z,8)=F-1
End If
If DX>60 and DX<65
Pen GREEN : Locate 0,31 : Input "Horizontal offset of auxilliary frame: ";QAW
ALANIM(AN,OP,Z,9)=QAW/2
End If
If DX>67 and DX<72
Pen GREEN : Locate 0,31 : Input "Vertical offset of auxilliary frame: ";QAW
ALANIM(AN,OP,Z,10)=QAW/2
End If
End If
Until Y=31 and X>60
Y=0
Return
ALIENNAMESHOW:
Cls 0
Locate 0,0
Pen GREEN
Centre "Currently Defined Aliens:"
For A=0 To ALMAX
Locate 0,A+1
Pen WHITE : Print A;
Pen GREEN
Locate 4,
Print ALNAME$(A);
Locate 40,
Pen RED
Print "| Define characteristics | Copy :-"
Next
Locate 0,29 : Pen RED
Centre "[ Change Scale of Alien ]"
Locate 0,31 : Pen RED
Centre "*** DONE ***"
Return
SETOBJNAME:
Menu Off
Repeat
Gosub OBJNAMESHOW
Repeat : MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)/8
X=X Screen(0,X Mouse)/8
Y=Y-1
If Y>=0 and Y<30
If MC=1
Locate 4,Y+1 : Pen RED : Input OBNAME$(Y)
Else
Gosub SETOBJSTATS
End If
End If
Until Y=30
Cls 0
Menu On
Return
SETOBJSTATS:
NO=Y
Repeat
Gosub OBJSTATSHOW
Repeat : MC=Mouse Click
Until MC<>0
Y=Y Screen(0,Y Mouse)/8
If Y=1
OBSTAT(NO,0)=(OBSTAT(NO,0)+1) and 3
End If
If Y=2
OBSTAT(NO,1)=(OBSTAT(NO,1)+1) mod 3
End If
If Y=3 and OBSTAT(NO,0)=1
Locate 40,3 : Pen RED
Input OBSTAT(NO,2)
End If
If Y=4 and OBSTAT(NO,0)=2
Locate 40,4 : Pen RED
Input OBSTAT(NO,3)
End If
If Y=5 and OBSTAT(NO,0)=2
Locate 40,5 : Pen RED
Input OBSTAT(NO,4)
End If
If Y=6 and OBSTAT(NO,0)>1
Locate 40,6 : Pen RED
OBSTAT(NO,5)=1-OBSTAT(NO,5)
End If
If Y=7
Gosub SETOBJDEFANIM
Y=-1
End If
If Y=8 and OBSTAT(NO,0)<>3
Gosub SETOBJACTANIM
Y=-1
End If
If Y=11 and OBSTAT(NO,0)<>2 and OBSTAT(NO,0)<>3
Gosub DEFAMMOGIVE : Y=-1
End If
If Y=10 and OBSTAT(NO,0)<>2 and OBSTAT(NO,0)<>3
Gosub DEFGUNGIVE : Y=-1
End If
If Y=12
Locate 40,12 : Pen RED : Input OBSTAT(NO,7)
End If
If Y=13
Locate 40,13 : Pen RED : Input O : OBSTAT(NO,8)=O/2
End If
If Y=14
OBSTAT(NO,9)=1-OBSTAT(NO,9)
End If
If Y=15
OBSTAT(NO,10)=1-OBSTAT(NO,10)
End If
If Y=16
Gosub SFXNAMESHOW
Gosub SFXNAMEPICK
OBSTAT(NO,12)=Y-1
Y=-1
End If
Until Y=31
Return
OBJSTATSHOW:
Cls 0
Locate 0,0
Pen GREEN
Centre "Characteristics of object type: "+OBNAME$(NO)
Locate 0,1
Pen WHITE
Print "Behaviour of object: "
Pen RED
Locate 40,1
If OBSTAT(NO,0)=0
Print "Collectable "
End If
If OBSTAT(NO,0)=1
Print "Activatable "
End If
If OBSTAT(NO,0)=2
Print "Destructable"
End If
If OBSTAT(NO,0)=3
Print "Decoration "
End If
Locate 0,2
Pen WHITE
Print "Graphic type: "
Pen RED
Locate 40,2
If OBSTAT(NO,1)=0
Print "Bitmap "
Else
If OBSTAT(NO,1)=1
Print "Polygon"
Else
Print "Glare/Smoke"
End If
End If
If OBSTAT(NO,0)=1
Locate 0,3
Pen WHITE
Print "Deactivate after (50ths/sec, -1=Never):"
Locate 40,3
Pen RED
If OBSTAT(NO,2)<>-1
Print OBSTAT(NO,2)
Else
Print "Never"
End If
End If
If OBSTAT(NO,0)=2
Locate 0,4
Pen WHITE
Print "Number of hit points: "
Locate 40,4
Pen RED
Print OBSTAT(NO,3)
Locate 0,5
Pen WHITE
Print "Explosive potential:"
Locate 40,5
Pen RED
Print OBSTAT(NO,4)
End If
If OBSTAT(NO,0)<>0 and OBSTAT(NO,0)<>1
Locate 0,6
Pen WHITE
Print "Impassable in default state (Y/N):"
Locate 40,6
Pen RED
If OBSTAT(NO,5)=0
Print "No"
Else
Print "Yes"
End If
End If
Pen RED
Locate 0,7
Centre "[ Define default state animation ]"
Locate 0,8
If OBSTAT(NO,0)<>3
Centre "[ Define active/destroyed animation ]"
End If
If OBSTAT(NO,0)=0 or OBSTAT(NO,0)=1
Pen WHITE : Locate 0,9
Print "Upon collection/activation, give player:-"
Pen RED : Locate 0,10
Centre "[ Define Guns/JetPack/Shield Given ]"
Locate 0,11
Centre "[ Define Ammo/Fuel Given ]"
End If
Locate 0,12 : Pen WHITE
Print "Collision cylinder radius:"
Locate 40,12 : Pen RED
Print OBSTAT(NO,7)
Locate 0,13 : Pen WHITE
Print "Collision cylinder height:"
Locate 40,13 : Pen RED
Print OBSTAT(NO,8)*2
Locate 0,14 : Pen WHITE
Print "Position vertically relative to: ";
Locate 40,14 : Pen RED
If OBSTAT(NO,9)=0
Print "FLOOR"
Else
Print "CEILING"
End If
Locate 0,15 : Pen WHITE
Print "Lock to nearest wall? ";
Locate 40,15 : Pen RED
YESNO[OBSTAT(NO,10)]
Locate 0,16 : Pen WHITE
If OBSTAT(NO,0)<>3
If OBSTAT(NO,0)=0
Print "Collection Sound Effect ";
Else If OBSTAT(NO,0)=1
Print "Activation Sound Effect ";
Else
Print "Destruction Sound Effect ";
End If
Locate 40,
Pen RED
If OBSTAT(NO,12)>=0
Print SFX$(OBSTAT(NO,12))
Else
Print "None."
End If
End If
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Return
DEFAMMOGIVE:
Repeat
Gosub AMMOGIVESHOW
Repeat : Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)/8
If Y>0 and Y<23
Locate 40,Y : Pen RED : Input AMMOGIVE(NO,Y-1)
End If
Until Y=31
Y=0
Return
AMMOGIVESHOW:
Cls 0
Locate 0,0 : Pen GREEN
Centre "Quantity given by "+OBNAME$(NO)+" when collected:"
Locate 0,1 : Pen WHITE
Print "Health:"
Locate 40,1 : Pen RED
Print AMMOGIVE(NO,0)
Locate 0,2 : Pen WHITE
Print "Jetpack Fuel:"
Locate 40,2 : Pen RED
Print AMMOGIVE(NO,1)
For A=0 To 19
Locate 0,A+3
Pen WHITE
Print "Ammo Type: ";BULNAME$(A);
Locate 40,
Pen RED
Print AMMOGIVE(NO,A+2)
Next
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Return
DEFGUNGIVE:
Repeat
Gosub GUNGIVESHOW
Repeat : Until Mouse Click<>0
Y=Y Screen(0,Y Mouse)/8
If Y>0 and Y<13
Locate 40,Y : GUNGIVE(NO,Y-1)=1-GUNGIVE(NO,Y-1)
End If
Until Y=31
Y=0
Return
Procedure YESNO[V]
If V=0 Then Print "No" Else Print "Yes"
End Proc
GUNGIVESHOW:
Cls 0
Locate 0,0 : Pen GREEN
Centre "Quantity given by "+OBNAME$(NO)+" when collected:"
Locate 0,1 : Pen WHITE
Print "Shield:"
Locate 40,1 : Pen RED
YESNO[GUNGIVE(NO,0)]
Locate 0,2 : Pen WHITE
Print "Jetpack:"
Locate 40,2 : Pen RED
YESNO[GUNGIVE(NO,1)]
For A=0 To 9
Locate 0,A+3
Pen WHITE
Print "Gun Type: ";GUNNAME$(A);
Locate 40,
Pen RED
YESNO[GUNGIVE(NO,A+2)]
Next
Locate 0,31 : Pen RED : Centre "*** DONE ***"
Return
OBJNAMESHOW:
Cls 0
Locate 0,0
Pen GREEN
Centre "Currently Defined Objects:"
For A=0 To 29
Locate 0,A+1
Pen WHITE : Print A;
Pen GREEN
Locate 4,
Print OBNAME$(A);
Next
Pen RED : Locate 0,31
Centre "*** DONE ***"
Return
SETOBJDEFANIM:
If OBSTAT(NO,1)<>1
Gosub SETDEFBITMAPANIM
Else
Gosub SETDEFPOLYANIM
End If
Return
SETOBJACTANIM:
If OBSTAT(NO,1)<>1
Gosub SETACTBITMAPANIM
Else
Gosub SETACTPOLYANIM
End If
Return
SETDEFBITMAPANIM:
Repeat
Gosub OBDEFANIMSHOW
Repeat
MC=Mouse Click
Until MC<>0
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
If Y=31
If X<15
OBSTAT(NO,6)=Min(OBSTAT(NO,6)+1,19)
For J=0 To 4
OBDEFAF(NO,OBSTAT(NO,6),J)=OBDEFAF(NO,OBSTAT(NO,6)-1,J)
OBDEFAF(NO,OBSTAT(NO,6)-1,5)=OBSTAT(NO,6)
OBDEFAF(NO,OBSTAT(NO,6),5)=OBSTAT(NO,6)
Next
Else
If X<30
OBSTAT(NO,6)=Max(OBSTAT(NO,6)-1,0)
For Q=0 To OBSTAT(NO,6)
If OBDEFAF(NO,Q,5)=OBSTAT(NO,6)+1
OBDEFAF(NO,Q,5)=OBSTAT(NO,6)
End If
Next
End If
End If
End If
Z=(Y-1)
'+(X/40)*30
DX=X
'mod 40
If Y>0 and Y<=OBSTAT(NO,6)+1
If DX>6 and DX<10
Gosub PICKOBJGRAPHNAME
OBDEFAF(NO,Z,0)=Y-1
End If
If DX>12 and DX<16
If MC=2
FRAMEPICK[OBDEFAF(NO,Z,0),OBDEFAF(NO,Z,1)+1]
OBDEFAF(NO,Z,1)=Param-1
Gosub OBDEFANIMSHOW
Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";O : OBDEFAF(NO,Z,1)=O-1
End If
End If
If DX>18 and DX<23
Pen GREEN
Locate 0,31 : Input "SCALED WIDTH :";OBDEFAF(NO,Z,2);
End If
If DX>25 and DX<30
Pen GREEN
Locate 0,31 : Input "SCALED HEIGHT :";OBDEFAF(NO,Z,3);
End If
If DX>32 and DX<37
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";O; : OBDEFAF(NO,Z,4)=O/2
End If
If DX>39
Pen GREEN : Locate 0,31 : Print "SELECT NEXT FRAME:- ";
Repeat
Until Mouse Click
NS=Y Screen(0,Y Mouse)/8
If NS>0 and NS<=OBSTAT(NO,6)+1
OBDEFAF(NO,Z,5)=NS-1
End If
End If
End If
Until Y=31 and X>60
Return
OBDEFANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Default Animation Frames for "+OBNAME$(NO)
Print A$
For A=0 To OBSTAT(NO,6)
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print Using "## ";A;
Print "GF:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,1)+1;
Pen WHITE
Print "SW:";
Pen RED
Print Using "### ";OBDEFAF(NO,A,2);
Pen WHITE
Print "SH:";
Pen RED
Print Using "### ";OBDEFAF(NO,A,3);
Pen WHITE
Print "VO:";
Pen RED
Print Using "+### ";OBDEFAF(NO,A,4)*2;
Pen WHITE
Print "NF:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,5);
Print
Next
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
SETDEFPOLYANIM:
Repeat
Gosub OBDEFPOLYANIMSHOW
Repeat
MC=Mouse Click
Until MC<>0
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
If Y=31
If X<15
OBSTAT(NO,6)=Min(OBSTAT(NO,6)+1,19)
For J=0 To 4
OBDEFAF(NO,OBSTAT(NO,6),J)=OBDEFAF(NO,OBSTAT(NO,6)-1,J)
OBDEFAF(NO,OBSTAT(NO,6)-1,5)=OBSTAT(NO,6)
OBDEFAF(NO,OBSTAT(NO,6),5)=OBSTAT(NO,6)
Next
Else
If X<30
OBSTAT(NO,6)=Max(OBSTAT(NO,6)-1,0)
For Q=0 To OBSTAT(NO,6)
If OBDEFAF(NO,Q,5)=OBSTAT(NO,6)+1
OBDEFAF(NO,Q,5)=OBSTAT(NO,6)
End If
Next
End If
End If
End If
Z=(Y-1)
'+(X/40)*30
DX=X
' mod 40
If Y>0 and Y<31
If DX>3 and DX<7
Gosub PICKVECTORNAME
OBDEFAF(NO,Z,0)=Y-1
End If
If DX>9 and DX<13
' If MC=2
' FRAMEPICK[OBDEFAF(NO,Z,0),OBDEFAF(NO,Z,1)]
' OBDEFAF(NO,Z,1)=Param
' Gosub OBDEFANIMSHOW
' Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";O : OBDEFAF(NO,Z,1)=O-1
' End If
End If
If DX>15 and DX<20
Pen GREEN
Locate 0,31 : Input "ANGLE OFFSET (8192=360 deg) :";ANGL
OBDEFAF(NO,Z,2)=ANGL/256
OBDEFAF(NO,Z,3)=ANGL and 255
End If
' If DX>22 and DX<27
' Pen GREEN
' Locate 0,31 : Input "SCALED HEIGHT :";OBDEFAF(NO,Z,3);
' End If
If DX>31 and DX<36
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";O; : OBDEFAF(NO,Z,4)=O/2
End If
If DX>39
Pen GREEN : Locate 0,31 : Print "SELECT NEXT FRAME:- ";
Repeat
Until Mouse Click
NS=Y Screen(0,Y Mouse)/8
If NS>0 and NS<=OBSTAT(NO,6)+1
OBDEFAF(NO,Z,5)=NS-1
End If
End If
End If
Until Y=31 and X>60
Return
OBDEFPOLYANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Default Vector Animation Frames for "+OBNAME$(NO)
Print A$
For A=0 To OBSTAT(NO,6)
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen GREEN
Print Using "##";A;
Pen WHITE
Print "VF:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,1)+1;
Pen WHITE
Print "AO:";
Pen RED
Print Using "####";OBDEFAF(NO,A,2)*256+OBDEFAF(NO,A,3);
Pen WHITE
Print " ";
Pen RED
'Print Using "### ";OBDEFAF(NO,A,3);
Print " ";
Pen WHITE
Print "VO:";
Pen RED
Print Using "+### ";OBDEFAF(NO,A,4)*2;
Pen WHITE
Print "NF:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,5);
Print
Next
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
SETACTBITMAPANIM:
Repeat
Gosub OBACTANIMSHOW
Repeat
MC=Mouse Click
Until MC<>0
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
If Y=31
If X<15
OBSTAT(NO,6)=Min(OBSTAT(NO,6)+1,19)
For J=0 To 4
OBDEFAF(NO,OBSTAT(NO,6),J)=OBDEFAF(NO,OBSTAT(NO,6)-1,J)
OBDEFAF(NO,OBSTAT(NO,6)-1,5)=OBSTAT(NO,6)
OBDEFAF(NO,OBSTAT(NO,6),5)=OBSTAT(NO,6)
Next
Else
If X<30
OBSTAT(NO,6)=Max(OBSTAT(NO,6)-1,0)
For Q=0 To OBSTAT(NO,6)
If OBDEFAF(NO,Q,5)=OBSTAT(NO,6)+1
OBDEFAF(NO,Q,5)=OBSTAT(NO,6)
End If
Next
End If
End If
End If
Z=(Y-1)
'+(X/40)*30
DX=X
' mod 40
If Y>0 and Y<31
If DX>3 and DX<7
Gosub PICKOBJGRAPHNAME
OBACTAF(NO,Z,0)=Y-1
End If
If DX>9 and DX<13
If MC=2
FRAMEPICK[OBACTAF(NO,Z,0),OBACTAF(NO,Z,1)+1]
OBACTAF(NO,Z,1)=Param-1
Gosub OBDEFANIMSHOW
Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";O : OBACTAF(NO,Z,1)=O-1
End If
End If
If DX>15 and DX<20
Pen GREEN
Locate 0,31 : Input "SCALED WIDTH :";OBACTAF(NO,Z,2);
End If
If DX>22 and DX<27
Pen GREEN
Locate 0,31 : Input "SCALED HEIGHT :";OBACTAF(NO,Z,3);
End If
If DX>29 and DX<34
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";O; : OBACTAF(NO,Z,4)=O/2
End If
If DX>39
Pen GREEN : Locate 0,31 : Print "SELECT NEXT FRAME:- ";
Repeat
Until Mouse Click
NS=Y Screen(0,Y Mouse)/8
If NS>0 and NS<=OBSTAT(NO,6)+1
OBDEFAF(NO,Z,5)=NS-1
End If
End If
End If
Until Y=31 and X>60
Return
OBACTANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Activated Animation Frames for "+OBNAME$(NO)
Print A$
For A=0 To OBSTAT(NO,11)
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print "GF:";
Pen RED
Print Using "## ";OBACTAF(NO,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";OBACTAF(NO,A,1)+1;
Pen WHITE
Print "SW:";
Pen RED
Print Using "### ";OBACTAF(NO,A,2);
Pen WHITE
Print "SH:";
Pen RED
Print Using "### ";OBACTAF(NO,A,3);
Pen WHITE
Print "VO:";
Pen RED
Print Using "+### ";OBACTAF(NO,A,4)*2;
Pen WHITE
Print "NF:";
Pen RED
Print Using "## ";OBDEFAF(NO,A,5);
Print
Next
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return
SETACTPOLYANIM:
Repeat
Gosub OBACTPOLYANIMSHOW
Repeat
MC=Mouse Click
Until MC<>0
X=X Screen(0,X Mouse)/8
Y=Y Screen(0,Y Mouse)/8
If Y=31
If X<15
OBSTAT(NO,11)=Min(OBSTAT(NO,11)+1,19)
For J=0 To 4
OBACTAF(NO,OBSTAT(NO,11),J)=OBACTAF(NO,OBSTAT(NO,11)-1,J)
OBACTAF(NO,OBSTAT(NO,11)-1,5)=OBSTAT(NO,11)
OBACTAF(NO,OBSTAT(NO,11),5)=OBSTAT(NO,11)
Next
Else
If X<30
OBSTAT(NO,11)=Max(OBSTAT(NO,11)-1,0)
For Q=0 To OBSTAT(NO,11)
If OBACTAF(NO,Q,5)=OBSTAT(NO,11)+1
OBACTAF(NO,Q,5)=OBSTAT(NO,11)
End If
Next
End If
End If
End If
Z=(Y-1)
'+(X/40)*30
DX=X
' mod 40
If Y>0 and Y<31
If DX>3 and DX<7
Gosub PICKVECTORNAME
OBACTAF(NO,Z,0)=Y-1
End If
If DX>9 and DX<13
' If MC=2
' FRAMEPICK[OBactAF(NO,Z,0),OBactAF(NO,Z,1)]
' OBactAF(NO,Z,1)=Param
' Gosub OBactANIMSHOW
' Else
Pen GREEN
Locate 0,31 : Input "FRAME NUMBER :";O : OBACTAF(NO,Z,1)=O-1
' End If
End If
If DX>15 and DX<20
Pen GREEN
Locate 0,31 : Input "ANGLE OFFSET (8192=360 deg) :";ANGL
OBACTAF(NO,Z,2)=ANGL/256
OBACTAF(NO,Z,3)=ANGL and 255
End If
' If DX>22 and DX<27
' Pen GREEN
' Locate 0,31 : Input "SCALED HEIGHT :";OBACTAF(NO,Z,3);
' End If
If DX>29 and DX<34
Pen GREEN
Locate 0,31 : Input "VERTICAL OFFSET:";O; : OBACTAF(NO,Z,4)=O/2
End If
If DX>39
Pen GREEN : Locate 0,31 : Print "SELECT NEXT FRAME:- ";
Repeat
Until Mouse Click
NS=Y Screen(0,Y Mouse)/8
If NS>0 and NS<=OBSTAT(NO,11)+1
OBACTAF(NO,Z,5)=NS-1
End If
End If
End If
Until Y=31 and X>60
Return
OBACTPOLYANIMSHOW:
Cls 0
Pen GREEN : Paper 0
Locate 0,0
A$="Activated Vector Animation Frames for "+OBNAME$(NO)
Print A$
For A=0 To OBSTAT(NO,11)
B=(A mod 30)+1
C=(A/30)*40
Locate C,B
Pen WHITE
Print "VF:";
Pen RED
Print Using "## ";OBACTAF(NO,A,0)+1;
Pen WHITE
Print "FN:";
Pen RED
Print Using "## ";OBACTAF(NO,A,1)+1;
Pen WHITE
Print "AO:";
Pen RED
Print Using "####";OBACTAF(NO,A,2)*256+OBACTAF(NO,A,3);
Pen WHITE
Print " ";
Pen RED
'Print Using "### ";OBactAF(NO,A,3);
Print " ";
Pen WHITE
Print "VO:";
Pen RED
Print Using "+### ";OBACTAF(NO,A,4)*2;
Pen WHITE
Print "NF:";
Pen RED
Print Using "## ";OBACTAF(NO,A,5);
Print
Next
Locate 0,31
Pen GREEN
Print " * ADD FRAME * * DEL FRAME * ";
Locate 60,31
Pen RED
Print "*** DONE ***";
Return